|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.lotus.xsl.XMLParserLiaisonDefault
This class is the default XMLParserLiaison for the XSL Processor. It can be used alone, for programmatically built DOMs (I expect this use will be very rare), or it can be derived from, in order to make parser specific implementations.
Field Summary | |
java.lang.String |
m_attrSpecialChars
These are characters that will be escaped in the output. |
FormatterListener |
m_formatterListener
|
XSLProcessor |
m_processor
A pointer back to the owning XSL processor, mainly for use for warning and error handling. |
boolean |
m_use_validation
If set to true, validation will be performed. |
static java.lang.String |
S_XMLNAMESPACEURI
|
Constructor Summary | |
XMLParserLiaisonDefault()
Construct an instance. |
Method Summary | |
com.lotus.xsl.Document |
createDocument()
Create an empty DOM Document. |
com.lotus.xsl.Element |
getElementByID(java.lang.String id,
com.lotus.xsl.Document doc)
Given an ID, return the element. |
java.lang.String |
getExpandedAttributeName(com.lotus.xsl.Attr attr)
Returns the attribute name with the namespace expanded. |
java.lang.String |
getExpandedElementName(com.lotus.xsl.Element elem)
Returns the element name with the namespace expanded. |
FormatterListener |
getFormatterListener()
Get an instance of the formatter listener that is associated with this formatter. |
int |
getIndent()
Get the amount to indent when indent-result="yes". |
java.lang.String |
getLocalNameOfNode(com.lotus.xsl.Node n)
Returns the local name of the given node. |
java.lang.String |
getNamespaceForPrefix(java.lang.String prefix,
com.lotus.xsl.Element namespaceContext)
Given a prefix and a namespace context, return the expanded namespace. |
java.lang.String |
getNamespaceOfNode(com.lotus.xsl.Node n)
Returns the namespace of the given node. |
com.lotus.xsl.Node |
getParentOfNode(com.lotus.xsl.Node node)
I have to write this silly, and expensive function, because the DOM WG decided that attributes don't have parents. |
java.lang.String |
getParserDescription()
Return a string suitible for telling the user what parser is being used. |
boolean |
getShouldExpandEntityRefs()
get whether or not to expand all entity references in the source and style trees. |
java.lang.String |
getSpecialCharacters()
Get special characters for attributes that will be escaped. |
boolean |
getUseValidation()
If set to true, validation will be performed. |
boolean |
isIgnorableWhitespace(com.lotus.xsl.Text node)
Tell if the node is ignorable whitespace. |
com.lotus.xsl.Document |
parseXMLStream(java.io.Reader reader)
Parse the text pointed at by the reader as XML, and return a DOM Document interface. |
com.lotus.xsl.Document |
parseXMLStream(java.io.Reader reader,
java.lang.String filename)
Parse the text pointed at by the reader as XML, and return a DOM Document interface. |
com.lotus.xsl.Document |
parseXMLStream(java.net.URL url)
Parse the text pointed at by the URL, and return a DOM Document interface. |
void |
setFormatterListener(FormatterListener fl)
Set an instance of the formatter listener that is associated with this formatter. |
void |
setFormatterListener(java.io.PrintWriter pw,
java.lang.String resultns,
boolean format)
Set an instance of the formatter listener that is associated with this formatter. |
void |
setIndent(int i)
Set the amount to indent when indent-result="yes". |
void |
setProcessorOwner(XSLProcessor processor)
Set which processor this instance is associated with, mainly for use for error and warning handling. |
void |
SetShouldExpandEntityRefs(boolean b)
Set whether or not to expand all entity references in the source and style trees. |
void |
setSpecialCharacters(java.lang.String str)
Set special characters for attributes that will be escaped. |
void |
setUseValidation(boolean b)
If set to true, validation will be performed. |
void |
toMarkup(com.lotus.xsl.Document doc,
java.io.PrintWriter pw,
java.lang.String resultns,
boolean format)
Print a DOM tree. |
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
public XSLProcessor m_processor
public boolean m_use_validation
public java.lang.String m_attrSpecialChars
public static final java.lang.String S_XMLNAMESPACEURI
public FormatterListener m_formatterListener
Constructor Detail |
public XMLParserLiaisonDefault()
Method Detail |
public java.lang.String getParserDescription()
public int getIndent()
public void setIndent(int i)
public boolean getShouldExpandEntityRefs()
public void SetShouldExpandEntityRefs(boolean b)
public boolean getUseValidation()
public void setUseValidation(boolean b)
public void setSpecialCharacters(java.lang.String str)
public java.lang.String getSpecialCharacters()
public void setProcessorOwner(XSLProcessor processor)
public com.lotus.xsl.Document parseXMLStream(java.io.Reader reader) throws java.io.IOException, XSLProcessorException
reader
- A stream that should hold valid XML.public com.lotus.xsl.Document parseXMLStream(java.io.Reader reader, java.lang.String filename) throws java.io.IOException, XSLProcessorException
public com.lotus.xsl.Document parseXMLStream(java.net.URL url) throws java.io.IOException, XSLProcessorException
public com.lotus.xsl.Document createDocument()
public java.lang.String getNamespaceForPrefix(java.lang.String prefix, com.lotus.xsl.Element namespaceContext)
public java.lang.String getNamespaceOfNode(com.lotus.xsl.Node n)
public java.lang.String getLocalNameOfNode(com.lotus.xsl.Node n)
public java.lang.String getExpandedElementName(com.lotus.xsl.Element elem)
public java.lang.String getExpandedAttributeName(com.lotus.xsl.Attr attr)
public boolean isIgnorableWhitespace(com.lotus.xsl.Text node)
public com.lotus.xsl.Node getParentOfNode(com.lotus.xsl.Node node) throws java.lang.RuntimeException
public com.lotus.xsl.Element getElementByID(java.lang.String id, com.lotus.xsl.Document doc)
public void setFormatterListener(java.io.PrintWriter pw, java.lang.String resultns, boolean format)
public void setFormatterListener(FormatterListener fl)
public FormatterListener getFormatterListener()
public void toMarkup(com.lotus.xsl.Document doc, java.io.PrintWriter pw, java.lang.String resultns, boolean format) throws java.lang.Exception
doc
- The result tree.pw
- The PrintWriter to print the contents to.resultns
- the value of the resultns attribute.format
- Tells if it should be pretty-printed.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |