public static class CapabilityReferenceRecorder.DefaultCapabilityReferenceRecorder extends Object implements CapabilityReferenceRecorder
CapabilityReferenceRecorder.
Derives the required capability name from the baseRequirementName provided to the constructor and from
the attribute value. Derives the dependent capability name from the baseDependentName provided to the
constructor, and, if the dependent name is dynamic, from the address of the resource currently being processed.CapabilityReferenceRecorder.DefaultCapabilityReferenceRecorder| Constructor and Description |
|---|
DefaultCapabilityReferenceRecorder(String baseRequirementName,
String baseDependentName,
boolean dynamicDependent) |
| Modifier and Type | Method and Description |
|---|---|
void |
addCapabilityRequirements(OperationContext context,
String attributeName,
String... attributeValues)
Registers capability requirement information to the given context.
|
protected String |
getDynamicDependentName(PathAddress currentAddress)
Determines the dynamic portion of the dependent capability's name.
|
void |
removeCapabilityRequirements(OperationContext context,
String attributeName,
String... attributeValues)
Deregisters capability requirement information from the given context.
|
public final void addCapabilityRequirements(OperationContext context, String attributeName, String... attributeValues)
CapabilityReferenceRecorderaddCapabilityRequirements in interface CapabilityReferenceRecordercontext - the contextattributeName - the name of the attributepublic final void removeCapabilityRequirements(OperationContext context, String attributeName, String... attributeValues)
CapabilityReferenceRecorderremoveCapabilityRequirements in interface CapabilityReferenceRecordercontext - the contextattributeName - the name of the attributeprotected String getDynamicDependentName(PathAddress currentAddress)
dynamicDependent
is set to true in the constructor.
This base implementation returns the value of the last element in currentAddress. Subclasses that
wish to extract the relevant name from some other element in the address may override this.
currentAddress - the address of the resource currently being processed. Will not be nullnullCopyright © 2015 JBoss by Red Hat. All rights reserved.