org.apache.xalan.processor
Class XSLTSchema

java.lang.Object
  extended by org.apache.xalan.processor.XSLTElementDef
      extended by org.apache.xalan.processor.XSLTSchema

public class XSLTSchema
extends XSLTElementDef

This class defines the allowed structure for a stylesheet, and the mapping between Xalan classes and the markup elements in the stylesheet.

See Also:
XSLT DTD

Field Summary
private  java.util.HashMap m_availElems
          A hashtable of all available built-in elements for use by the element-available function.
 
Fields inherited from class org.apache.xalan.processor.XSLTElementDef
m_isOrdered, m_requiredFound, T_ANY, T_ELEMENT, T_PCDATA
 
Constructor Summary
XSLTSchema()
          Construct a XSLTSchema which represents the XSLT "schema".
 
Method Summary
(package private)  void addAvailableElement(QName elemName)
          Adds a new element name to the Hashtable of available elements.
(package private)  void build()
          This method builds an XSLT "schema" according to http://www.w3.org/TR/xslt#dtd.
 boolean elementAvailable(QName elemName)
          Determines whether the passed element name is present in the list of available elements.
 java.util.HashMap getElemsAvailable()
          Get the table of available elements.
 
Methods inherited from class org.apache.xalan.processor.XSLTElementDef
build, getAttributeDef, getAttributes, getClassObject, getElementProcessor, getElements, getLastOrder, getMultiAllowed, getName, getNameAlias, getNamespace, getOrder, getProcessorFor, getProcessorForUnknown, getRequired, getRequiredElem, getRequiredFound, getType, hasRequired, isOrdered, setElementProcessor, setElements, setLastOrder, setRequiredFound, setType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_availElems

private java.util.HashMap m_availElems
A hashtable of all available built-in elements for use by the element-available function. TODO: When we convert to Java2, this should be a Set.

Constructor Detail

XSLTSchema

XSLTSchema()
Construct a XSLTSchema which represents the XSLT "schema".

Method Detail

build

void build()
This method builds an XSLT "schema" according to http://www.w3.org/TR/xslt#dtd. This schema provides instructions for building the Xalan Stylesheet (Templates) structure.


getElemsAvailable

public java.util.HashMap getElemsAvailable()
Get the table of available elements.

Returns:
table of available elements, keyed by qualified names, and with values of the same qualified names.

addAvailableElement

void addAvailableElement(QName elemName)
Adds a new element name to the Hashtable of available elements.

Parameters:
elemName - The name of the element to add to the Hashtable of available elements.

elementAvailable

public boolean elementAvailable(QName elemName)
Determines whether the passed element name is present in the list of available elements.

Parameters:
elemName - The name of the element to look up.
Returns:
true if an element corresponding to elemName is available.