org.inria.ns.reflex.processor.asl
Class AttributeAction.NameRef.AttributeNameMatcher

java.lang.Object
  extended by org.inria.ns.reflex.processor.asl.ItemMatcher
      extended by org.inria.ns.reflex.processor.asl.AttributeAction.Matcher
          extended by org.inria.ns.reflex.processor.asl.AttributeAction.NameRef.AttributeNameMatcher
All Implemented Interfaces:
Reducible
Enclosing class:
AttributeAction.NameRef

public class AttributeAction.NameRef.AttributeNameMatcher
extends AttributeAction.Matcher

A concrete material item given by an attribute reference.


Field Summary
 
Fields inherited from class org.inria.ns.reflex.processor.asl.ItemMatcher
FOUND, NOT_FOUND
 
Constructor Summary
AttributeAction.NameRef.AttributeNameMatcher()
           
 
Method Summary
 AttributeDefinition getAttributeDefinition()
           
 QName getAttributeName()
           
 boolean isLocal()
          Indicates whether the definition is local or not.
 TypedData matches(QName attributeName, DataSet dataSet)
          Test if an attribute name matches this material.
 ValidationError reportError(Element element, Node candidate)
          Raise an error.
 
Methods inherited from class org.inria.ns.reflex.processor.asl.AttributeAction.Matcher
getAction, getSchema, matches
 
Methods inherited from class org.inria.ns.reflex.processor.asl.ItemMatcher
canUse, getExceptions, getInterimStep, getMaxInit, getMaxRest, getMinInit, getMinRest, mustUse, reset, runInterim, setBoundaries, setInterimStep, use
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AttributeAction.NameRef.AttributeNameMatcher

public AttributeAction.NameRef.AttributeNameMatcher()
Method Detail

getAttributeName

public QName getAttributeName()

matches

public TypedData matches(QName attributeName,
                         DataSet dataSet)
Test if an attribute name matches this material.

Specified by:
matches in class AttributeAction.Matcher
Parameters:
attributeName - The name of the attribute to test.
dataSet - The set of datas used when the matcher is matching.
Returns:
FOUND if the object matches this material and carries no data, a TypedData if the object matches this material and carries a data, NOT_FOUND otherwise.
See Also:
ItemMatcher.matches(Object,org.inria.ns.reflex.processor.DataSet)

getAttributeDefinition

public AttributeDefinition getAttributeDefinition()

isLocal

public boolean isLocal()
Indicates whether the definition is local or not.

Overrides:
isLocal in class AttributeAction.Matcher
Returns:
true if an attribute definition has been set, false otherwise.

reportError

public ValidationError reportError(Element element,
                                   Node candidate)
Raise an error. This method is used by the SchemaClientHandler when a candidate material failed to match whereas it is expected.

Specified by:
reportError in class ItemMatcher
Parameters:
element - The element in fault.
candidate - The candidate node that cause the fault.
Returns:
The validation error raised.