|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.xalan.xsltc.compiler.Parser
Constructor Summary | |
Parser(XSLTC xsltc)
|
Method Summary | |
void |
addParameter(org.apache.xalan.xsltc.compiler.Param param)
|
void |
addVariable(org.apache.xalan.xsltc.compiler.Variable var)
|
void |
characters(char[] ch,
int start,
int length)
SAX2: Receive notification of character data. |
void |
createAST(Stylesheet stylesheet)
Instanciates a SAX2 parser and generate the AST from the input. |
boolean |
elementSupported(java.lang.String namespace,
java.lang.String localName)
|
void |
endDocument()
SAX2: Receive notification of the end of a document. |
void |
endElement(java.lang.String uri,
java.lang.String localname,
java.lang.String qname)
SAX2: Receive notification of the end of an element. |
void |
endPrefixMapping(java.lang.String prefix)
SAX2: End the scope of a prefix-URI Namespace mapping. |
boolean |
errorsFound()
Returns true if there were any errors during compilation |
boolean |
functionSupported(java.lang.String fname)
|
int |
getCurrentImportPrecedence()
|
Stylesheet |
getCurrentStylesheet()
|
SyntaxTreeNode |
getDocumentRoot()
|
java.util.Vector |
getErrors()
|
org.apache.xalan.xsltc.compiler.QName |
getExcludeResultPrefixes()
|
org.apache.xalan.xsltc.compiler.QName |
getExtensionElementPrefixes()
|
int |
getNextImportPrecedence()
|
org.apache.xalan.xsltc.compiler.Output |
getOutput()
|
java.util.Properties |
getOutputProperties()
|
org.apache.xalan.xsltc.compiler.QName |
getQName(org.apache.xalan.xsltc.compiler.QName scope,
org.apache.xalan.xsltc.compiler.QName name)
|
org.apache.xalan.xsltc.compiler.QName |
getQName(java.lang.String stringRep)
|
org.apache.xalan.xsltc.compiler.QName |
getQName(java.lang.String stringRep,
boolean reportError)
|
org.apache.xalan.xsltc.compiler.QName |
getQName(java.lang.String scope,
java.lang.String name)
|
org.apache.xalan.xsltc.compiler.QName |
getQName(java.lang.String namespace,
java.lang.String prefix,
java.lang.String localname)
|
org.apache.xalan.xsltc.compiler.QName |
getQNameIgnoreDefaultNs(java.lang.String stringRep)
|
org.apache.xalan.xsltc.compiler.QName |
getQNameSafe(java.lang.String stringRep)
|
org.apache.xalan.xsltc.compiler.SymbolTable |
getSymbolTable()
|
Template |
getTemplate()
|
int |
getTemplateIndex()
|
Stylesheet |
getTopLevelStylesheet()
|
org.apache.xalan.xsltc.compiler.QName |
getUseAttributeSets()
|
java.util.Vector |
getWarnings()
|
XSLTC |
getXSLTC()
|
void |
ignorableWhitespace(char[] ch,
int start,
int length)
IGNORED - all ignorable whitespace is ignored |
void |
init()
|
org.apache.xalan.xsltc.compiler.VariableBase |
lookupVariable(org.apache.xalan.xsltc.compiler.QName name)
|
SyntaxTreeNode |
makeInstance(java.lang.String uri,
java.lang.String prefix,
java.lang.String local,
Attributes attributes)
|
Stylesheet |
makeStylesheet(SyntaxTreeNode element)
Create an instance of the Stylesheet class,
and then parse, typecheck and compile the instance. |
SyntaxTreeNode |
parse(InputSource input)
Parses a stylesheet and builds the internal abstract syntax tree |
SyntaxTreeNode |
parse(XMLReader reader,
InputSource input)
Parses a stylesheet and builds the internal abstract syntax tree |
org.apache.xalan.xsltc.compiler.Expression |
parseExpression(SyntaxTreeNode parent,
java.lang.String exp)
Parse an XPath expression: |
org.apache.xalan.xsltc.compiler.Expression |
parseExpression(SyntaxTreeNode parent,
java.lang.String attr,
java.lang.String def)
Parse an XPath expression: |
Pattern |
parsePattern(SyntaxTreeNode parent,
java.lang.String pattern)
Parse an XPath pattern: |
Pattern |
parsePattern(SyntaxTreeNode parent,
java.lang.String attr,
java.lang.String def)
Parse an XPath pattern: |
void |
printErrors()
Prints all compile-time errors |
void |
printWarnings()
Prints all compile-time warnings |
void |
processingInstruction(java.lang.String name,
java.lang.String value)
SAX2: Receive notification of a processing instruction. |
void |
removeVariable(org.apache.xalan.xsltc.compiler.QName name)
|
void |
reportError(int category,
ErrorMsg error)
Common error/warning message handler |
void |
setCurrentStylesheet(Stylesheet stylesheet)
|
void |
setDocumentLocator(Locator locator)
Store the document locator to later retrieve line numbers of all elements from the stylesheet |
void |
setOutput(org.apache.xalan.xsltc.compiler.Output output)
|
void |
setTemplate(Template template)
|
void |
setXSLTC(XSLTC xsltc)
|
void |
skippedEntity(java.lang.String name)
IGNORED - we do not have to do anything with skipped entities |
void |
startDocument()
SAX2: Receive notification of the beginning of a document. |
void |
startElement(java.lang.String uri,
java.lang.String localname,
java.lang.String qname,
Attributes attributes)
SAX2: Receive notification of the beginning of an element. |
void |
startPrefixMapping(java.lang.String prefix,
java.lang.String uri)
SAX2: Begin the scope of a prefix-URI Namespace mapping. |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public Parser(XSLTC xsltc)
Method Detail |
public void init()
public void setOutput(org.apache.xalan.xsltc.compiler.Output output)
public org.apache.xalan.xsltc.compiler.Output getOutput()
public java.util.Properties getOutputProperties()
public void addVariable(org.apache.xalan.xsltc.compiler.Variable var)
public void addParameter(org.apache.xalan.xsltc.compiler.Param param)
public void removeVariable(org.apache.xalan.xsltc.compiler.QName name)
public org.apache.xalan.xsltc.compiler.VariableBase lookupVariable(org.apache.xalan.xsltc.compiler.QName name)
public void setXSLTC(XSLTC xsltc)
public XSLTC getXSLTC()
public int getCurrentImportPrecedence()
public int getNextImportPrecedence()
public void setCurrentStylesheet(Stylesheet stylesheet)
public Stylesheet getCurrentStylesheet()
public Stylesheet getTopLevelStylesheet()
public org.apache.xalan.xsltc.compiler.QName getQNameSafe(java.lang.String stringRep)
public org.apache.xalan.xsltc.compiler.QName getQName(java.lang.String stringRep)
public org.apache.xalan.xsltc.compiler.QName getQNameIgnoreDefaultNs(java.lang.String stringRep)
public org.apache.xalan.xsltc.compiler.QName getQName(java.lang.String stringRep, boolean reportError)
public org.apache.xalan.xsltc.compiler.QName getQName(java.lang.String namespace, java.lang.String prefix, java.lang.String localname)
public org.apache.xalan.xsltc.compiler.QName getQName(java.lang.String scope, java.lang.String name)
public org.apache.xalan.xsltc.compiler.QName getQName(org.apache.xalan.xsltc.compiler.QName scope, org.apache.xalan.xsltc.compiler.QName name)
public org.apache.xalan.xsltc.compiler.QName getUseAttributeSets()
public org.apache.xalan.xsltc.compiler.QName getExtensionElementPrefixes()
public org.apache.xalan.xsltc.compiler.QName getExcludeResultPrefixes()
public Stylesheet makeStylesheet(SyntaxTreeNode element) throws CompilerException
Stylesheet
class,
and then parse, typecheck and compile the instance.
Must be called after parse()
.public void createAST(Stylesheet stylesheet)
public SyntaxTreeNode parse(XMLReader reader, InputSource input)
reader
- A SAX2 SAXReader (parser)input
- A SAX2 InputSource can be passed to a SAX readerpublic SyntaxTreeNode parse(InputSource input)
input
- A SAX2 InputSource can be passed to a SAX readerpublic SyntaxTreeNode getDocumentRoot()
public boolean elementSupported(java.lang.String namespace, java.lang.String localName)
public boolean functionSupported(java.lang.String fname)
public org.apache.xalan.xsltc.compiler.SymbolTable getSymbolTable()
public Template getTemplate()
public void setTemplate(Template template)
public int getTemplateIndex()
public SyntaxTreeNode makeInstance(java.lang.String uri, java.lang.String prefix, java.lang.String local, Attributes attributes)
public org.apache.xalan.xsltc.compiler.Expression parseExpression(SyntaxTreeNode parent, java.lang.String exp)
public org.apache.xalan.xsltc.compiler.Expression parseExpression(SyntaxTreeNode parent, java.lang.String attr, java.lang.String def)
public Pattern parsePattern(SyntaxTreeNode parent, java.lang.String pattern)
public Pattern parsePattern(SyntaxTreeNode parent, java.lang.String attr, java.lang.String def)
public boolean errorsFound()
public void printErrors()
public void printWarnings()
public void reportError(int category, ErrorMsg error)
public java.util.Vector getErrors()
public java.util.Vector getWarnings()
public void startDocument()
public void endDocument()
public void startPrefixMapping(java.lang.String prefix, java.lang.String uri)
public void endPrefixMapping(java.lang.String prefix)
public void startElement(java.lang.String uri, java.lang.String localname, java.lang.String qname, Attributes attributes) throws SAXException
public void endElement(java.lang.String uri, java.lang.String localname, java.lang.String qname)
public void characters(char[] ch, int start, int length)
public void processingInstruction(java.lang.String name, java.lang.String value)
public void ignorableWhitespace(char[] ch, int start, int length)
public void skippedEntity(java.lang.String name)
public void setDocumentLocator(Locator locator)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |