com.atlassian.bamboo.v2.build.agent.capability
Interface CapabilitySet

All Superinterfaces:
BambooObject, ReadOnlyCapabilitySet
All Known Subinterfaces:
ImageCapabilitySet
All Known Implementing Classes:
CapabilitySetImpl, ImageCapabilitySetImpl, LocalCapabilitySet, RemoteCapabilitySet

public interface CapabilitySet
extends ReadOnlyCapabilitySet, BambooObject


Method Summary
 void addCapability(Capability capability)
          Add a capability to the set.
 void addCapability(Capability capability, boolean overwrite)
          Adds a capability.
 CapabilityScope getCapabilityScope()
          The scope of the capability set.
 java.lang.String getCapabilitySetType()
          Returns the identifier describing the type of this capability.
 java.lang.String getSharedCapabilitySetType()
          Returns the identifier for the set if it is shared.
 void removeCapability(java.lang.String key)
          Remove a capability from the set, by the key.
 void setCapabilities(java.util.Set<Capability> capabilities)
           
 
Methods inherited from interface com.atlassian.bamboo.v2.build.agent.capability.ReadOnlyCapabilitySet
getCapabilities, getCapability
 
Methods inherited from interface com.atlassian.bamboo.core.BambooObject
getId, setId
 

Method Detail

addCapability

void addCapability(@NotNull
                   Capability capability)
Add a capability to the set. Will overwrite any existing capability key

Parameters:
capability -

addCapability

void addCapability(@NotNull
                   Capability capability,
                   boolean overwrite)
Adds a capability. If overwrite is false the new value will be rejected

Parameters:
capability -
overwrite -

removeCapability

void removeCapability(@NotNull
                      java.lang.String key)
Remove a capability from the set, by the key.

Parameters:
key -

setCapabilities

void setCapabilities(java.util.Set<Capability> capabilities)

getCapabilityScope

@NotNull
CapabilityScope getCapabilityScope()
The scope of the capability set. Can either be CapabilityScope.AGENT - only applies to one agent. or CapabilityScope.SHARED - shared across all local, or all remote agents.

Returns:
CapabilityScope

getSharedCapabilitySetType

@Nullable
java.lang.String getSharedCapabilitySetType()
Returns the identifier for the set if it is shared. Pretty used exclusively in the UI.

Returns:
"Local", "Remote" or null it not a shared capability type;

getCapabilitySetType

@Nullable
java.lang.String getCapabilitySetType()
Returns the identifier describing the type of this capability.

Returns:
"Local", "Remote" or "Image"


Copyright © 2010 Atlassian. All Rights Reserved.