Package org.jboss.as.controller
Interface CapabilityReferenceRecorder
-
- All Known Implementing Classes:
CapabilityReferenceRecorder.CompositeAttributeDependencyRecorder
,CapabilityReferenceRecorder.ContextDependencyRecorder
,CapabilityReferenceRecorder.DefaultCapabilityReferenceRecorder
,CapabilityReferenceRecorder.ResourceCapabilityReferenceRecorder
public interface CapabilityReferenceRecorder
Records information about capability reference information encoded in an attribute's value.- Author:
- Brian Stansberry (c) 2015 Red Hat Inc.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
CapabilityReferenceRecorder.CompositeAttributeDependencyRecorder
CapabilityReferenceRecorder
that determines the dependent capability from theOperationContext
and any additional attributes on same resource.static class
CapabilityReferenceRecorder.ContextDependencyRecorder
CapabilityReferenceRecorder
that determines the dependent capability from theOperationContext
.static class
CapabilityReferenceRecorder.DefaultCapabilityReferenceRecorder
Default implementation ofCapabilityReferenceRecorder
.static class
CapabilityReferenceRecorder.ResourceCapabilityReferenceRecorder
CapabilityReferenceRecorder
that determines the dependent and required capability from thePathAddress
of the resource registration.
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description void
addCapabilityRequirements(OperationContext context, Resource resource, String attributeName, String... attributeValues)
Registers capability requirement information to the given context.String
getBaseDependentName()
Deprecated.No longer required and may throwUnsupportedOperationException
String
getBaseRequirementName()
default String[]
getRequirementPatternSegments(String name, PathAddress address)
Returns the elements to be added to the baseRequirementName to build the capability name pattern.default boolean
isDynamicDependent()
Deprecated.No longer required and may throwUnsupportedOperationException
void
removeCapabilityRequirements(OperationContext context, Resource resource, String attributeName, String... attributeValues)
Deregisters capability requirement information from the given context.
-
-
-
Method Detail
-
addCapabilityRequirements
void addCapabilityRequirements(OperationContext context, Resource resource, String attributeName, String... attributeValues)
Registers capability requirement information to the given context.- Parameters:
context
- the contextresource
- the resource on which requirements are gatheredattributeName
- the name of the attributeattributeValues
- the values of the attribute, which may contain null
-
removeCapabilityRequirements
void removeCapabilityRequirements(OperationContext context, Resource resource, String attributeName, String... attributeValues)
Deregisters capability requirement information from the given context.- Parameters:
context
- the contextresource
- the resource on which requirements are gatheredattributeName
- the name of the attributeattributeValues
- the values of the attribute, which may contain null
-
getBaseDependentName
@Deprecated String getBaseDependentName()
Deprecated.No longer required and may throwUnsupportedOperationException
- Returns:
- base name of dependant, usually name of the attribute that provides reference to capability
-
getBaseRequirementName
String getBaseRequirementName()
- Returns:
- requirement name of the capability this reference depends on
-
isDynamicDependent
@Deprecated default boolean isDynamicDependent()
Deprecated.No longer required and may throwUnsupportedOperationException
- Returns:
- tells is reference is dynamic or static, in case where it is dynamic it uses base name + name of dependent attribute to construct name of capability
-
getRequirementPatternSegments
default String[] getRequirementPatternSegments(String name, PathAddress address)
Returns the elements to be added to the baseRequirementName to build the capability name pattern. It will return an array of the form `segment[.segment]` where each segment represents either the name of one of the resource's attributes or one of the keys in the resource's address. In the actual name the attribute name or address key will be replaced by the value associated with that attribute or key.- Parameters:
name
- the name of the attribute.address
- the registration address of the resource definition that has the capability and its requirement.- Returns:
- the elements to be added to the baseRequirementName to build the capability name pattern.
-
-