Class CapabilityContextImpl
- java.lang.Object
-
- com.atlassian.bamboo.v2.build.agent.capability.CapabilityContextImpl
-
- All Implemented Interfaces:
CapabilityContext
public class CapabilityContextImpl extends Object implements CapabilityContext
-
-
Constructor Summary
Constructors Constructor Description CapabilityContextImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clearCapabilitySet()
Removes whatever is currently stored in thread local@Nullable ReadOnlyCapabilitySet
getCapabilitySet()
Retrieves the capability set currently stored within the context, If empty the shared local (server) capabilities are returned@Nullable String
getCapabilityValue(@NotNull String key)
Convenience method.void
setCapabilitySet(@Nullable ReadOnlyCapabilitySet capabilitySet)
Stores a specific capability set within the ThreadLocal
-
-
-
Method Detail
-
getCapabilitySet
@Nullable public @Nullable ReadOnlyCapabilitySet getCapabilitySet()
Description copied from interface:CapabilityContext
Retrieves the capability set currently stored within the context, If empty the shared local (server) capabilities are returned- Specified by:
getCapabilitySet
in interfaceCapabilityContext
- Returns:
- ReadOnlyCapabilitySet
-
setCapabilitySet
public void setCapabilitySet(@Nullable @Nullable ReadOnlyCapabilitySet capabilitySet)
Description copied from interface:CapabilityContext
Stores a specific capability set within the ThreadLocal- Specified by:
setCapabilitySet
in interfaceCapabilityContext
-
clearCapabilitySet
public void clearCapabilitySet()
Description copied from interface:CapabilityContext
Removes whatever is currently stored in thread local- Specified by:
clearCapabilitySet
in interfaceCapabilityContext
-
getCapabilityValue
@Nullable public @Nullable String getCapabilityValue(@NotNull @NotNull String key)
Description copied from interface:CapabilityContext
Convenience method. Retrieves value of capability.- Specified by:
getCapabilityValue
in interfaceCapabilityContext
- Parameters:
key
- capability key- Returns:
- capability value or null if there are no capabilities set or there's no capability of given key
-
-