com.caucho.relaxng.pattern
Class ElementPattern

java.lang.Object
  extended by com.caucho.relaxng.pattern.Pattern
      extended by com.caucho.relaxng.pattern.ElementPattern

public class ElementPattern
extends Pattern

Relax element pattern


Field Summary
 
Fields inherited from class com.caucho.relaxng.pattern.Pattern
L
 
Constructor Summary
ElementPattern(java.lang.String defName)
          Creates a new element pattern.
 
Method Summary
 void addChild(Pattern child)
          Adds an element.
 void addNameChild(NameClassPattern child)
          Adds an element.
 Item createItem(GrammarPattern grammar)
          Creates the item, i.e.
 void endElement()
          Ends the element.
 boolean equals(java.lang.Object o)
           
 java.lang.String getDefName()
          Returns the definition name.
 NameClassPattern getNameChild()
          Adds an element.
 java.lang.String getTagName()
          Returns the Relax schema name.
 boolean hasElement()
          Returns true if it contains an element.
 java.lang.String toProduction()
          Returns a string for the production.
 java.lang.String toString()
          Debugging.
 
Methods inherited from class com.caucho.relaxng.pattern.Pattern
createNameItem, error, getElementName, getLocation, getParent, hasData, setElementName, setFilename, setLine, setParent
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ElementPattern

public ElementPattern(java.lang.String defName)
Creates a new element pattern.

Method Detail

getTagName

public java.lang.String getTagName()
Returns the Relax schema name.

Overrides:
getTagName in class Pattern

getDefName

public java.lang.String getDefName()
Returns the definition name.


hasElement

public boolean hasElement()
Returns true if it contains an element.

Overrides:
hasElement in class Pattern

addNameChild

public void addNameChild(NameClassPattern child)
                  throws RelaxException
Adds an element.

Overrides:
addNameChild in class Pattern
Throws:
RelaxException

getNameChild

public NameClassPattern getNameChild()
                              throws RelaxException
Adds an element.

Throws:
RelaxException

addChild

public void addChild(Pattern child)
              throws RelaxException
Adds an element.

Overrides:
addChild in class Pattern
Throws:
RelaxException

endElement

public void endElement()
                throws RelaxException
Ends the element.

Overrides:
endElement in class Pattern
Throws:
RelaxException

createItem

public Item createItem(GrammarPattern grammar)
                throws RelaxException
Creates the item, i.e. program

Overrides:
createItem in class Pattern
Throws:
RelaxException

toProduction

public java.lang.String toProduction()
Returns a string for the production.

Overrides:
toProduction in class Pattern

equals

public boolean equals(java.lang.Object o)
Specified by:
equals in class Pattern

toString

public java.lang.String toString()
Debugging.

Overrides:
toString in class java.lang.Object