org.apache.xalan.processor
Class XSLTSchema

java.lang.Object
  extended byorg.apache.xalan.processor.XSLTElementDef
      extended byorg.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  Hashtable 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
(package private) 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.
 Hashtable 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 Hashtable 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 Hashtable 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.