Class RequirementImpl
java.lang.Object
com.atlassian.core.bean.EntityObject
com.atlassian.bamboo.core.BambooEntityObject
com.atlassian.bamboo.v2.build.agent.capability.RequirementImpl
- All Implemented Interfaces:
BambooIdProvider,BambooObject,Requirement,ImmutableRequirement,Cloneable
- Direct Known Subclasses:
AgentAssignmentRequirement
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.atlassian.bamboo.v2.build.requirement.ImmutableRequirement
ImmutableRequirement.MatchType -
Field Summary
Fields inherited from interface com.atlassian.bamboo.v2.build.agent.capability.Requirement
EQUALS, EXISTS, REGEX -
Constructor Summary
ConstructorsConstructorDescriptionRequirementImpl(@NotNull Requirement requirement) RequirementImpl(String key, boolean regexMatch, String match) RequirementImpl(String key, boolean regexMatch, String match, boolean readonly) -
Method Summary
Modifier and TypeMethodDescriptionbooleanintboolean@NotNull StringgetKey()Represents the requirement.A match requirement value.longThe identifier of thisRequirementthat is used to identify it uniquely for allRequirements created byImmutableRequirement.getPluginModuleKey()TheModuleDescriptor.getKey()that is responsible for the Lifecycle of thisRequirement@NotNull ImmutableRequirement.MatchTypeinthashCode()If a requirement is readonly, it cannot be removed through the UI (the backend can do what it wants, however)booleanIs this a regex match requirement or exact match requirement.booleanIs this a system requirement? System requirements are builder/jdk requirements which cannot be removed from the plan.voidvoidsetMatchValue(String matchValue) voidsetOwnerId(long uniqueIdentifier) voidsetPluginModuleKey(String pluginModuleKey) voidsetReadonly(Boolean readonly) voidsetRegexMatch(Boolean regexMatch) voidsetRequirementSet(RequirementSet requirementSet) toString()Methods inherited from class com.atlassian.core.bean.EntityObject
clone, getCreationDate, getCurrentDate, getId, getLastModificationDate, setClock, setCreationDate, setId, setLastModificationDateMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.atlassian.bamboo.core.BambooIdProvider
getIdMethods inherited from interface com.atlassian.bamboo.core.BambooObject
setId
-
Constructor Details
-
RequirementImpl
public RequirementImpl() -
RequirementImpl
-
RequirementImpl
-
RequirementImpl
-
-
Method Details
-
isSystemRequirement
public boolean isSystemRequirement()Description copied from interface:RequirementIs this a system requirement? System requirements are builder/jdk requirements which cannot be removed from the plan.- Specified by:
isSystemRequirementin interfaceRequirement- Returns:
-
getKey
Description copied from interface:ImmutableRequirementRepresents the requirement. Must match exactly to theCapabilitygetKey().- Specified by:
getKeyin interfaceImmutableRequirement- Returns:
-
setKey
- Specified by:
setKeyin interfaceRequirement
-
getMatchValue
Description copied from interface:ImmutableRequirementA match requirement value. Even "EXISTS" matches are represented as a regex match with match value ".*"The regex must match the
Capabilityvalue.- Specified by:
getMatchValuein interfaceImmutableRequirement- Returns:
- the value to match.
-
setMatchValue
-
isRegexMatch
public boolean isRegexMatch()Description copied from interface:RequirementIs this a regex match requirement or exact match requirement.- Specified by:
isRegexMatchin interfaceImmutableRequirement- Specified by:
isRegexMatchin interfaceRequirement- Returns:
-
setRegexMatch
-
isReadonly
Description copied from interface:ImmutableRequirementIf a requirement is readonly, it cannot be removed through the UI (the backend can do what it wants, however)- Specified by:
isReadonlyin interfaceImmutableRequirement- Returns:
- true if the requirement cannot be removed or edited via the UI.
-
setReadonly
- Specified by:
setReadonlyin interfaceRequirement
-
getRequirementSet
- Specified by:
getRequirementSetin interfaceRequirement- Returns:
- requirementSet that this
Requirementis linked to
-
setRequirementSet
- Specified by:
setRequirementSetin interfaceRequirement
-
getTypeOfMatch
- Specified by:
getTypeOfMatchin interfaceImmutableRequirement- Returns:
- representing the type of match
-
getPluginModuleKey
Description copied from interface:ImmutableRequirementTheModuleDescriptor.getKey()that is responsible for the Lifecycle of thisRequirement- Specified by:
getPluginModuleKeyin interfaceImmutableRequirement- Returns:
- pluginKey
-
setPluginModuleKey
- Specified by:
setPluginModuleKeyin interfaceRequirement
-
getOwnerId
public long getOwnerId()Description copied from interface:ImmutableRequirementThe identifier of thisRequirementthat is used to identify it uniquely for allRequirements created byImmutableRequirement.getPluginModuleKey()- Specified by:
getOwnerIdin interfaceImmutableRequirement- Returns:
- ownerId
-
setOwnerId
public void setOwnerId(long uniqueIdentifier) - Specified by:
setOwnerIdin interfaceRequirement
-
belongsToPlugin
public boolean belongsToPlugin()- Specified by:
belongsToPluginin interfaceRequirement- Returns:
- true if this
Requirementbelongs to a plugin
-
toString
-
hashCode
public int hashCode()- Overrides:
hashCodein classcom.atlassian.core.bean.EntityObject
-
equals
- Overrides:
equalsin classcom.atlassian.core.bean.EntityObject
-
compareTo
-