Interface CapabilityType
-
- All Superinterfaces:
Comparable<CapabilityType>
- All Known Subinterfaces:
CapabilityTypeModule
- All Known Implementing Classes:
AbstractCapabilityType,AbstractCapabilityTypeModule,AbstractExecutableCapabilityTypeModule,AbstractMultipleExecutableCapabilityTypeModule,AgentEnvironmentCapabilityType,BuilderCapabilityType,GenericCapabilityType,GitCapabilityTypeModule,JdkCapabilityType,KubectlCapabilityType,PerforceCapabilityType,SshCapabilityTypeModule
public interface CapabilityType extends Comparable<CapabilityType>
Effectively a capability type object that specifies certain behaviour characteristics.A CapabilityType module may optionally implement the
CapabilityDefaultsHelperinterface for server- and agent-side capability auto detection.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description @NotNull CapabilitygetCapability(@NotNull Map<String,String[]> params)Returns a new capability given the action params map@NotNull StringgetCapabilityTypeKey()The key for the type typically lower case@NotNull StringgetCapabilityTypeLabel()Human readable version of the keydefault StringgetCapabilityTypeSpecificTaskConfigurationKey()Get task configuration key for the capability type.@Nullable StringgetExtraInfo(@NotNull String key)Displayed after the label@NotNull StringgetLabel(@NotNull String key)The display label@NotNull StringgetNewKeyFromLabel(@NotNull String oldKey, @NotNull String label)From the key and label, return a new key.intgetSortOrder()Specifies how early in the UI the type should be shown@Nullable StringgetValueDescriptionKey(@NotNull String key, @Nullable String value)Given the key and value, show any custom description for the value@Nullable StringgetViewTypeAction()The action name of the list view action of this capability typebooleanisAllowRename()Can you rename the key for this typevoidupdatePlanForNewLabel(@NotNull Buildable plan, @NotNull String oldLabel, @NotNull String newLabel)Deprecated.since 6.5 it doesn't work, modification of build definition requires use of manager.@NotNull Map<String,String>validate(@NotNull Map<String,String[]> params)Validate given an action params map.-
Methods inherited from interface java.lang.Comparable
compareTo
-
-
-
-
Method Detail
-
getSortOrder
int getSortOrder()
Specifies how early in the UI the type should be shown- Returns:
-
getCapabilityTypeKey
@NotNull @NotNull String getCapabilityTypeKey()
The key for the type typically lower case- Returns:
-
getCapabilityTypeLabel
@NotNull @NotNull String getCapabilityTypeLabel()
Human readable version of the key
-
getViewTypeAction
@Nullable @Nullable String getViewTypeAction()
The action name of the list view action of this capability type- Returns:
-
validate
@NotNull @NotNull Map<String,String> validate(@NotNull @NotNull Map<String,String[]> params)
Validate given an action params map.- Parameters:
params-- Returns:
- Map with errors. key = field name, value = error message
-
getCapability
@NotNull @NotNull Capability getCapability(@NotNull @NotNull Map<String,String[]> params)
Returns a new capability given the action params map- Parameters:
params-
-
getLabel
@NotNull @NotNull String getLabel(@NotNull @NotNull String key)
The display label- Parameters:
key-- Returns:
-
getExtraInfo
@Nullable @Nullable String getExtraInfo(@NotNull @NotNull String key)
Displayed after the label- Parameters:
key-- Returns:
-
getValueDescriptionKey
@Nullable @Nullable String getValueDescriptionKey(@NotNull @NotNull String key, @Nullable @Nullable String value)
Given the key and value, show any custom description for the value- Parameters:
key-value-- Returns:
-
isAllowRename
boolean isAllowRename()
Can you rename the key for this type- Returns:
-
getNewKeyFromLabel
@NotNull @NotNull String getNewKeyFromLabel(@NotNull @NotNull String oldKey, @NotNull @NotNull String label)
From the key and label, return a new key. This is used in the rename process- Parameters:
oldKey-label-- Returns:
-
getCapabilityTypeSpecificTaskConfigurationKey
default String getCapabilityTypeSpecificTaskConfigurationKey()
Get task configuration key for the capability type.- Since:
- 6.5
-
updatePlanForNewLabel
@Deprecated void updatePlanForNewLabel(@NotNull @NotNull Buildable plan, @NotNull @NotNull String oldLabel, @NotNull @NotNull String newLabel)
Deprecated.since 6.5 it doesn't work, modification of build definition requires use of manager.Perform custom work when the key has been updated.- Parameters:
plan-oldLabel- label to replacenewLabel- new label
-
-