|
Unicorn XML Toolkit Version 1.50.00 |
|||||||||
� PREV CLASS ��NEXT CLASS | FRAMES��NO FRAMES | |||||||||
SUMMARY: � CONSTR �|� FUNCTION �|�DATA | DETAIL: � CONSTR �|� FUNCTION �|�DATA |
class CToolkitBase: public CInterface { public: CToolkitBase(); ~CToolkitBase(); public: CXmlBase *GetXmlBase(); CDomBase *GetDomBase(); CXpathBase *GetXpathBase(); CXsltBase *GetXsltBase(); public: Sax::XXmlReader CreateXmlReader(); XXmlWriter CreateXmlWriter(); public: Dom::XDocument CreateDomDocument(const WCHAR *pszClass=_W("")); XDomReader CreateDomReader(Dom::INode *pNode=NULL); XDomWriter CreateDomWriter(Dom::INode *pNode=NULL); public: XXpathExpr CreateXpathExpr(const WCHAR *pszSource); XXpathContext CreateXpathContext(CXpathNodeSet *pNodeSet); XXpathContext CreateXpathContext( Dom::INode *pNode, int nCount=1, int nPosition=1); public: XXsltStylesheet CreateXsltStylesheet(const WCHAR *pszUri); XXsltStylesheet CreateXsltStylesheet( const WCHAR *pszUri, Dom::INode *pNode); XXsltStylesheet CreateXsltStylesheet( const WCHAR *pszUri, Sax::CXmlReader *pReader); XXsltProcessor CreateXsltProcessor(); public: void SetErrorStream(IUnicodeStream *pErrorStream); IUnicodeStream *GetErrorStream(); }; typedef XInterface<CToolkitBase> XToolkitBase;
Encapsulates core toolkit functionality.
This class provides the root for data structures supporting core toolkit object classes, which include:
Several other public methods of this class are intended mainly for the internal toolkit use and are not discussed here.
Various toolkit extensions normally rely in these core classes and therefore also use the toolkit base class.
CToolkitBase, CXmlBase, CDomBase, CXpathBase, CXsltBase, CXmlWriter, CDomReader, CDomWriter, CXpathNodeSet, CXpathContext, CXpathExpr, CXsltStylesheet, CXsltProcessor, CXsltStylesheet, CXsltProcessor, Sax::CXmlReader, Dom::INode, Dom::IDocument
Constructor/Destructor Summary | |
CToolkitBase
();
����������Constructs the toolkit base. |
|
~CToolkitBase
();
����������Destroys the toolkit base. |
Function Summary | |
CXmlBase�*
|
GetXmlBase
();
����������Returns the toolkit XML base. |
CDomBase�*
|
GetDomBase
();
����������Returns the toolkit DOM base. |
CXpathBase�*
|
GetXpathBase
();
����������Returns the toolkit XPath base. |
CXsltBase�*
|
GetXsltBase
();
����������Returns the toolkit XSLT base. |
Sax::XXmlReader
|
CreateXmlReader
();
����������Creates an XML parser. |
XXmlWriter
|
CreateXmlWriter
();
����������Creates a new XML writer. |
Dom::XDocument
|
CreateDomDocument
(const WCHAR *pszClass=_W(""));
����������Creates a new DOM/XDM document. |
XDomReader
|
CreateDomReader
(Dom::INode *pNode=NULL);
����������Creates a new DOM reader. |
XDomWriter
|
CreateDomWriter
(Dom::INode *pNode=NULL);
����������Creates a new DOM writer. |
XXpathExpr
|
CreateXpathExpr
(const WCHAR *pszSource);
����������Creates the XPath expression. |
XXpathContext
|
CreateXpathContext
(CXpathNodeSet *pNodeSet);
����������Creates the XPath context from the XPath node set. |
XXpathContext
|
CreateXpathContext
(Dom::INode *pNode, int nCount=1, int nPosition=1);
����������Creates the XPath context from the context node, context size, and context position. |
XXsltStylesheet
|
CreateXsltStylesheet
(const WCHAR *pszUri);
����������Creates the precompiled XSLT stylesheet from an XML document located via URI. |
XXsltStylesheet
|
CreateXsltStylesheet
(const WCHAR *pszUri, Dom::INode *pNode);
����������Creates the precompiled XSLT stylesheet from an XML fragment rooted at the specified DOM/XDM node. |
XXsltStylesheet
|
CreateXsltStylesheet
(const WCHAR *pszUri, Sax::CXmlReader *pReader);
����������Creates the precompiled XSLT stylesheet from a content stream provided by the specified SAX XML reader. |
XXsltProcessor
|
CreateXsltProcessor
();
����������Creates the new XSLT processor. |
void
|
SetErrorStream
(IUnicodeStream *pErrorStream);
����������Sets a Unicode text stream for reporting non-fatal errors. |
IUnicodeStream�*
|
GetErrorStream
();
����������Returns the error stream. |
Constructor/Destructor Detail |
CToolkitBase();
Constructs the toolkit base.
~CToolkitBase();
Destroys the toolkit base.
Function Detail |
CXmlBase *GetXmlBase();
Returns the toolkit XML base.
CDomBase *GetDomBase();
Returns the toolkit DOM base.
CXpathBase *GetXpathBase();
Returns the toolkit XPath base.
CXsltBase *GetXsltBase();
Returns the toolkit XSLT base.
Sax::XXmlReader CreateXmlReader();
Creates an XML parser.
This function creates a new instance of the standard toolkit's
non-validating XML parser, implementing interface of
the abstract class
Sax::CXmlReader
.
XXmlWriter CreateXmlWriter();
Creates a new XML writer.
Dom::XDocument CreateDomDocument(const WCHAR *pszClass=_W(""));
Creates a new DOM/XDM document.
The document class must be specified to indicate the document
model. Supported values are
"DOM"
for DOM and
"XPath"
for XDM. The default (empty) value
indicates DOM.
The newly created document has initially empty content.
pszClass
- the class specifying the document modelXDomReader CreateDomReader(Dom::INode *pNode=NULL);
Creates a new DOM reader.
pNode
- the optional root of the sub-tree in
the DOM document serving as the source for this DOM reader.
If this parameter is set to
NULL
, the node must
be specified using the
SetNode
method
before starting the DOM reader.XDomWriter CreateDomWriter(Dom::INode *pNode=NULL);
Creates a new DOM writer.
pNode
- the node serving as the parent for
a sub-tree, which the DOM writer should build.
If this parameter is set to
NULL
,
the node must be specified using the
SetNode
method before starting the source stream of SAX content events.XXpathExpr CreateXpathExpr(const WCHAR *pszSource);
Creates the XPath expression.
This method takes the string representation of the XPath
expression, parses it, and stores result in the newly
created
CXpathExpr
object.
It is an error is the expression contains references to functions not from the XPath core function library, or to variables.
pszSource
- the string representation of
the XPath expressionXXpathContext CreateXpathContext(CXpathNodeSet *pNodeSet);
Creates the XPath context from the XPath node set.
See
CXpathContext
for details of node
set construction.
pNodeSet
- the XPath node setXXpathContext CreateXpathContext( Dom::INode *pNode, int nCount=1, int nPosition=1);
Creates the XPath context from the context node, context size, and context position.
The model of the context node must be XDM (that is, DOM nodes are not allowed).
See
CXpathContext
for details of node
set construction.
pNode
- the context nodenCount
- the context sizenPosition
- the context positionXXsltStylesheet CreateXsltStylesheet(const WCHAR *pszUri);
Creates the precompiled XSLT stylesheet from an XML document located via URI.
See
Uri
for details of the URI support.
pszUri
- the source URIXXsltStylesheet CreateXsltStylesheet( const WCHAR *pszUri, Dom::INode *pNode);
Creates the precompiled XSLT stylesheet from an XML fragment rooted at the specified DOM/XDM node.
The source URI passed to the method is used solely for resolving relative URI encountered in during the stylesheet parsing; this parameter may be set to the empty string if the stylesheet contains no relative URI, which need to be resolved.
The node passed to the method may be of DOM or XDM model; it must be either a document node or an element node corresponding to the stylesheet root element.
pszUri
- the source URIpNode
- the root of the sub-tree representing
the stylesheet sourceXXsltStylesheet CreateXsltStylesheet( const WCHAR *pszUri, Sax::CXmlReader *pReader);
Creates the precompiled XSLT stylesheet from a content stream provided by the specified SAX XML reader.
The source URI passed to the method is used solely for resolving relative URI encountered in during the stylesheet parsing; this parameter may be set to the empty string if the stylesheet contains no relative URI, which need to be resolved.
pszUri
- the source URIpReader
- the SAX XML reader providing
the SAX content stream representing the stylesheet sourceXXsltProcessor CreateXsltProcessor();
Creates the new XSLT processor.
void SetErrorStream(IUnicodeStream *pErrorStream);
Sets a Unicode text stream for reporting non-fatal errors.
pErrorStream
- the error streamIUnicodeStream *GetErrorStream();
Returns the error stream.
NULL
if none
was specified
|
Unicorn XML Toolkit Version 1.50.00 |
|||||||||
� PREV CLASS ��NEXT CLASS | FRAMES��NO FRAMES | |||||||||
SUMMARY: � CONSTR �|� FUNCTION �|�DATA | DETAIL: � CONSTR �|� FUNCTION �|�DATA |