Enum CapabilitySource
- java.lang.Object
-
- java.lang.Enum<CapabilitySource>
-
- com.atlassian.bamboo.v2.build.agent.capability.CapabilitySource
-
- All Implemented Interfaces:
Serializable
,Comparable<CapabilitySource>
public enum CapabilitySource extends Enum<CapabilitySource> implements Comparable<CapabilitySource>
Source where given agent capability is defined. Sources are defined in order of priority.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description AUTO_DETECTION
Automatically detectedPROPERTIES_FILE
Defined in bamboo-capabilities.properties fileSHARED
Shared remote capabilityUI
Added manually by user in UI
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static @Nullable CapabilitySource
forName(@NotNull String name)
Return a capability source for the given name.int
getMask()
Get bits that represents this sourcestatic CapabilitySource
valueOf(String name)
Returns the enum constant of this type with the specified name.static CapabilitySource[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.-
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Methods inherited from interface java.lang.Comparable
compareTo
-
-
-
-
Enum Constant Detail
-
UI
public static final CapabilitySource UI
Added manually by user in UI
-
PROPERTIES_FILE
public static final CapabilitySource PROPERTIES_FILE
Defined in bamboo-capabilities.properties file
-
AUTO_DETECTION
public static final CapabilitySource AUTO_DETECTION
Automatically detected
-
SHARED
public static final CapabilitySource SHARED
Shared remote capability
-
-
Method Detail
-
values
public static CapabilitySource[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (CapabilitySource c : CapabilitySource.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static CapabilitySource valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
forName
@Nullable public static @Nullable CapabilitySource forName(@NotNull @NotNull String name)
Return a capability source for the given name. Does a case-insensitive check.- Parameters:
name
- name of the capability source- Returns:
- the given capability source or null if not found
-
getMask
public int getMask()
Get bits that represents this source
-
-