org.jbind.xml.instance.use
Class ElemRefOrDeclUseState

java.lang.Object
  extended byorg.jbind.xml.instance.use.ContentUseState
      extended byorg.jbind.xml.instance.use.ElemUseState
          extended byorg.jbind.xml.instance.use.ElemRefOrDeclUseState
All Implemented Interfaces:
IElemRefOrDeclUseState, IElemUseState, IUseState

public class ElemRefOrDeclUseState
extends ElemUseState
implements IElemRefOrDeclUseState


Constructor Summary
ElemRefOrDeclUseState(IElemRefOrDecl aContent, IUseState aParent)
           
 
Method Summary
protected  void doIsValidEnd(IHasLocation aHasLocation)
           
 IElemDesc getElemDesc()
          Gets the data declaration that corresponds to the current state of the use state object.
 IElemUseState getNextUseState(java.lang.String aNamespace, java.lang.String aName, IAnyType anOverloadingType, IHasLocation aHasLocation)
          Gets the next use state that has a content use for the specified element.
 IElemRefOrDecl getSubstitutionHead()
           
 
Methods inherited from class org.jbind.xml.instance.use.ContentUseState
doReset, getContentDesc, getParent, getUseCounter, incrementUseCounter, isValidEnd, mayIncrementUseCounter, reset
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jbind.xml.core.content.IUseState
getContentDesc, getParent, getUseCounter, isValidEnd, reset
 

Constructor Detail

ElemRefOrDeclUseState

public ElemRefOrDeclUseState(IElemRefOrDecl aContent,
                             IUseState aParent)
Method Detail

getNextUseState

public IElemUseState getNextUseState(java.lang.String aNamespace,
                                     java.lang.String aName,
                                     IAnyType anOverloadingType,
                                     IHasLocation aHasLocation)
                              throws XmlException
Description copied from interface: IUseState
Gets the next use state that has a content use for the specified element.

Specified by:
getNextUseState in interface IUseState
Parameters:
aNamespace - (required).
aName - (required).
Returns:
(optional).
Throws:
XmlException - Raised if this use state needs to return the next use state (e.g. because it is a sequence that has been started) but the specified element does not match.

doIsValidEnd

protected void doIsValidEnd(IHasLocation aHasLocation)
Specified by:
doIsValidEnd in class ContentUseState

getElemDesc

public IElemDesc getElemDesc()
Description copied from interface: IElemUseState
Gets the data declaration that corresponds to the current state of the use state object. The returned data declaration will be used to create the next element. If an element was matched by a wildcard or by a substitute then the resolved element declaration is returned, i.e. the element declaration that is actually used to create a data object.

Specified by:
getElemDesc in interface IElemUseState
Returns:
(optional). If the element is to be skipped then null is returned.

getSubstitutionHead

public IElemRefOrDecl getSubstitutionHead()
Specified by:
getSubstitutionHead in interface IElemUseState