org.gcube.common.core.resources.service
Class Package

java.lang.Object
  extended by org.gcube.common.core.resources.service.Package
Direct Known Subclasses:
MainPackage, Plugin, Software

public class Package
extends Object


Nested Class Summary
static class Package.GHNRequirement
           
static class Package.MavenCoordinate
           
static class Package.ScopeLevel
           
 
Field Summary
protected  Map<Package.MavenCoordinate,String> coordinates
          Coordinates of the artifact in a Maven Repository
protected  String description
           
 
Constructor Summary
Package()
           
 
Method Summary
 boolean equals(Object obj)
           
 List<Dependency> getDependencies()
          Returns the package dependencies dependencies.
 String getDescription()
           
 List<Package.GHNRequirement> getGHNRequirements()
          Returns the GHN requirements for the package.
 List<String> getInstallScripts()
          Returns the names of the install scripts associated with the package.
 Package.ScopeLevel getMandatoryLevel()
          Returns the level of scope at which the package is mandatory.
 String getMavenCoordinate(Package.MavenCoordinate name)
          Gets a coordinate's value
 Boolean getMultiVersion()
          Indicates whether the package can coexist with previous versions on the same GHN.
 String getName()
          Returns the name of the package.
 List<String> getRebootScripts()
          Returns the names of the reboot scripts associated with the package.
 Package.ScopeLevel getSharingLevel()
          Returns the level of scope at which the package can be shared.
 String getSpecificData()
          Returns package-specific data.
 PlatformDescription getTargetPlatform()
           
 List<String> getUninstallScripts()
          Returns the names of the uninstall scripts associated with the package.
 String getVersion()
          Returns the package version.
 void setDescription(String description)
           
 void setGHNRequirements(List<Package.GHNRequirement> arg0)
           
 void setInstallScripts(List<String> installScripts)
          Sets the install scripts associated with the package.
 void setMandatoryLevel(Package.ScopeLevel level)
          Sets the level of scope at which the package is mandatory.
 void setMavenCoordinates(String groupId, String artifactId, String version, String... classifier)
          Sets the maven coordinates of the package
 void setMultiVersion(Boolean support)
          Indicates whether the package can coexist with previous versions on the same GHN.
 void setName(String arg0)
           
 void setRebootScripts(List<String> rebootScripts)
          Sets the reboot scripts associated with the package
 void setSharingLevel(Package.ScopeLevel level)
          Sets the level of scope at which the package can be shared.
 void setSpecificData(String data)
          Sets package-specific data.
 void setTargetPlatform(PlatformDescription targetPlatform)
           
 void setUninstallScripts(List<String> scripts)
           
 void setVersion(String version)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

description

protected String description

coordinates

protected Map<Package.MavenCoordinate,String> coordinates
Coordinates of the artifact in a Maven Repository

Constructor Detail

Package

public Package()
Method Detail

getName

public String getName()
Returns the name of the package.

Returns:
the name

getDependencies

public List<Dependency> getDependencies()
Returns the package dependencies dependencies.

Returns:
the dependencies.

getGHNRequirements

public List<Package.GHNRequirement> getGHNRequirements()
Returns the GHN requirements for the package.

Returns:
the requirements.

getInstallScripts

public List<String> getInstallScripts()
Returns the names of the install scripts associated with the package.

Returns:
the names.

getMultiVersion

public Boolean getMultiVersion()
Indicates whether the package can coexist with previous versions on the same GHN.

Returns:
true if it does, false otherwise.

setMultiVersion

public void setMultiVersion(Boolean support)
Indicates whether the package can coexist with previous versions on the same GHN.

Parameters:
support - true if it does, false otherwise.

getRebootScripts

public List<String> getRebootScripts()
Returns the names of the reboot scripts associated with the package.

Returns:
the names.

getUninstallScripts

public List<String> getUninstallScripts()
Returns the names of the uninstall scripts associated with the package.

Returns:
the names.

getVersion

public String getVersion()
Returns the package version.

Returns:
the version.

getMandatoryLevel

public Package.ScopeLevel getMandatoryLevel()
Returns the level of scope at which the package is mandatory.

Returns:
the scope level.

setMandatoryLevel

public void setMandatoryLevel(Package.ScopeLevel level)
Sets the level of scope at which the package is mandatory.

Parameters:
level - the scope level

getSharingLevel

public Package.ScopeLevel getSharingLevel()
Returns the level of scope at which the package can be shared.

Returns:
the level of scope.

setSharingLevel

public void setSharingLevel(Package.ScopeLevel level)
Sets the level of scope at which the package can be shared.

Parameters:
level - the scope level

setGHNRequirements

public void setGHNRequirements(List<Package.GHNRequirement> arg0)

setName

public void setName(String arg0)

setMavenCoordinates

public void setMavenCoordinates(String groupId,
                                String artifactId,
                                String version,
                                String... classifier)
Sets the maven coordinates of the package

Parameters:
groupId -
artifactId -
version -
classifier -

getMavenCoordinate

public String getMavenCoordinate(Package.MavenCoordinate name)
Gets a coordinate's value

Parameters:
name - the name
Returns:
the value

setUninstallScripts

public void setUninstallScripts(List<String> scripts)

setVersion

public void setVersion(String version)

setInstallScripts

public void setInstallScripts(List<String> installScripts)
Sets the install scripts associated with the package.

Parameters:
installScripts - the scripts.

setRebootScripts

public void setRebootScripts(List<String> rebootScripts)
Sets the reboot scripts associated with the package

Parameters:
rebootScripts - the scripts.

getSpecificData

public String getSpecificData()
Returns package-specific data.

Returns:
the data.

setSpecificData

public void setSpecificData(String data)
Sets package-specific data.

Parameters:
data - the data.

getDescription

public String getDescription()

setDescription

public void setDescription(String description)

setTargetPlatform

public void setTargetPlatform(PlatformDescription targetPlatform)
Parameters:
targetPlatform - the targetPlatform to set

getTargetPlatform

public PlatformDescription getTargetPlatform()
Returns:
the targetPlatform

equals

public boolean equals(Object obj)
Overrides:
equals in class Object


Copyright © 2012. All Rights Reserved.