Class DiscardUndefinedAttributesTransformer
java.lang.Object
org.jboss.as.controller.transform.DiscardUndefinedAttributesTransformer
- All Implemented Interfaces:
OperationTransformer,ResourceTransformer
public class DiscardUndefinedAttributesTransformer
extends Object
implements ResourceTransformer, OperationTransformer
Transformer that hides new attributes from legacy slaves if the attribute value is undefined. A defined value
leads to a log warning or an
OperationFailedException unless the resource is ignored by the target.- Author:
- Brian Stansberry (c) 2012 Red Hat Inc.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.jboss.as.controller.transform.OperationTransformer
OperationTransformer.TransformedOperation -
Field Summary
Fields inherited from interface org.jboss.as.controller.transform.OperationTransformer
DEFAULT, DEFAULT_REJECTION_POLICY, DISCARD, SUCCESSFUL_RESULTFields inherited from interface org.jboss.as.controller.transform.ResourceTransformer
DEFAULT, DISCARD -
Constructor Summary
ConstructorsConstructorDescriptionDiscardUndefinedAttributesTransformer(String... attributeNames) DiscardUndefinedAttributesTransformer(Set<String> attributeNames) DiscardUndefinedAttributesTransformer(AttributeDefinition... attributes) -
Method Summary
Modifier and TypeMethodDescriptiontransformOperation(TransformationContext context, PathAddress address, org.jboss.dmr.ModelNode operation) Transform the operation.voidtransformResource(ResourceTransformationContext context, PathAddress address, Resource resource) Transform a resource.
-
Constructor Details
-
DiscardUndefinedAttributesTransformer
-
DiscardUndefinedAttributesTransformer
-
DiscardUndefinedAttributesTransformer
-
-
Method Details
-
getWriteAttributeTransformer
-
getUndefineAttributeTransformer
-
transformResource
public void transformResource(ResourceTransformationContext context, PathAddress address, Resource resource) throws OperationFailedException Description copied from interface:ResourceTransformerTransform a resource.- Specified by:
transformResourcein interfaceResourceTransformer- Parameters:
context- the resource transformation contextaddress- the path addressresource- the resource to transform- Throws:
OperationFailedException
-
transformOperation
public OperationTransformer.TransformedOperation transformOperation(TransformationContext context, PathAddress address, org.jboss.dmr.ModelNode operation) throws OperationFailedException Description copied from interface:OperationTransformerTransform the operation.- Specified by:
transformOperationin interfaceOperationTransformer- Parameters:
context- the operation contextaddress- the path addressoperation- the operation- Returns:
- the transformed operation
- Throws:
OperationFailedException
-