Package org.jboss.as.controller
Interface CapabilityReferenceRecorder
-
- All Superinterfaces:
Feature
- All Known Implementing Classes:
CapabilityReferenceRecorder.CompositeAttributeDependencyRecorder,CapabilityReferenceRecorder.ContextDependencyRecorder,CapabilityReferenceRecorder.DefaultCapabilityReferenceRecorder,CapabilityReferenceRecorder.ResourceCapabilityReferenceRecorder
public interface CapabilityReferenceRecorder extends Feature
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 classCapabilityReferenceRecorder.CompositeAttributeDependencyRecorderCapabilityReferenceRecorderthat determines the dependent capability from theOperationContextand any additional attributes on same resource.static classCapabilityReferenceRecorder.ContextDependencyRecorderCapabilityReferenceRecorderthat determines the dependent capability from theOperationContext.static classCapabilityReferenceRecorder.DefaultCapabilityReferenceRecorderDefault implementation ofCapabilityReferenceRecorder.static classCapabilityReferenceRecorder.ResourceCapabilityReferenceRecorderCapabilityReferenceRecorderthat determines the dependent and required capability from thePathAddressof the resource registration.
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description voidaddCapabilityRequirements(OperationContext context, Resource resource, String attributeName, String... attributeValues)Registers capability requirement information to the given context.StringgetBaseDependentName()Deprecated, for removal: This API element is subject to removal in a future version.No longer required and may throwUnsupportedOperationExceptionStringgetBaseRequirementName()default String[]getRequirementPatternSegments(String name, PathAddress address)Returns the elements to be added to the baseRequirementName to build the capability name pattern.default booleanisDynamicDependent()Deprecated, for removal: This API element is subject to removal in a future version.No longer required and may throwUnsupportedOperationExceptionvoidremoveCapabilityRequirements(OperationContext context, Resource resource, String attributeName, String... attributeValues)Deregisters capability requirement information from the given context.-
Methods inherited from interface org.jboss.as.controller.Feature
getStability
-
-
-
-
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(forRemoval=true) String getBaseDependentName()
Deprecated, for removal: This API element is subject to removal in a future version.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(forRemoval=true) default boolean isDynamicDependent()
Deprecated, for removal: This API element is subject to removal in a future version.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. N.B. This parameter is only specified in association with a ResourcDefinition. When associated with an AttributeDefinition, address will always bePathAddress.EMPTY_ADDRESS.- Returns:
- the elements to be added to the baseRequirementName to build the capability name pattern.
-
-