Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.10

FormatterToXercesDOM.hpp
Go to the documentation of this file.
1 /*
2  * Copyright 1999-2004 The Apache Software Foundation.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 #if !defined(FORMATTERTOXERCESDOM_HEADER_GUARD_1357924680)
17 #define FORMATTERTOXERCESDOM_HEADER_GUARD_1357924680
18 
19 
20 
21 // Base include file. Must be first.
23 
24 
25 
27 
28 
29 
30 // Base class header file.
32 
33 
34 
36 
37 
38 
40 
41 
42 
43 XALAN_CPP_NAMESPACE_BEGIN
44 
45 
46 
52 {
53 public:
54 
64  DOMDocument_Type* doc,
65  DOMDocumentFragmentType* docFrag,
66  DOMElementType* currentElement,
68 
77  DOMDocument_Type* doc,
78  DOMElementType* currentElement,
79  MemoryManagerType& theManager XALAN_DEFAULT_MEMMGR);
80 
81  virtual
83 
84 
85  // These methods are inherited from DocumentHandler ...
86 
87  virtual void
89  const XMLCh* const chars,
90  const unsigned int length);
91 
92  virtual void
93  comment(const XMLCh* const data);
94 
95  virtual void
96  cdata(
97  const XMLCh* const ch,
98  const unsigned int length);
99 
100  virtual void
101  entityReference(const XMLCh* const name);
102 
103  virtual void
104  setDocumentLocator(const LocatorType* const locator);
105 
106  virtual void
107  startDocument();
108 
109  virtual void
110  endDocument();
111 
112  virtual void
113  startElement(
114  const XMLCh* const name,
115  AttributeListType& attrs);
116 
117  virtual void
118  endElement(const XMLCh* const name);
119 
120  virtual void
121  characters(
122  const XMLCh* const chars,
123  const unsigned int length);
124 
125  virtual void
127  const XMLCh* const chars,
128  const unsigned int length);
129 
130  virtual void
132  const XMLCh* const target,
133  const XMLCh* const data);
134 
135  virtual void
136  resetDocument();
137 
139  getDocument() const
140  {
141  return m_doc;
142  }
143 
144  void
145  setDocument(DOMDocument_Type* theDocument)
146  {
147  m_doc = theDocument;
148  }
149 
151  getDocumentFragment() const
152  {
153  return m_docFrag;
154  }
155 
156  void
157  setDocumentFragment(DOMDocumentFragmentType* theDocumentFragment)
158  {
159  m_docFrag = theDocumentFragment;
160  }
161 
163  getCurrentElement() const
164  {
165  return m_currentElem;
166  }
167 
168  void
169  setCurrentElement(DOMElementType* theElement)
170  {
171  m_currentElem = theElement;
172  }
173 
174 private:
175 
179  void
180  processAccumulatedText();
181 
185  void
186  append(DOMNodeType* newNode);
187 
196  createElement(
197  const XalanDOMChar* theElementName,
198  AttributeListType& attrs);
199 
200  void
201  addAttributes(
202  DOMElementType* theElement,
203  AttributeListType& attrs);
204 
205 
206  // Data members...
207  DOMDocument_Type* m_doc;
208 
209  DOMDocumentFragmentType* m_docFrag;
210 
211  DOMElementType* m_currentElem;
212 
213  typedef XalanVector<DOMElementType*> ElementStackType;
214 
215  ElementStackType m_elemStack;
216 
217  XalanDOMString m_buffer;
218 
219  XalanDOMString m_textBuffer;
220 
221  static const XalanDOMString s_emptyString;
222 };
223 
224 
225 
226 XALAN_CPP_NAMESPACE_END
227 
228 
229 
230 #endif // FORMATTERTODOM_HEADER_GUARD_1357924680

Interpreting class diagrams

Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.

dot

Xalan-C++ XSLT Processor Version 1.10
Copyright © 1999-2004 The Apache Software Foundation. All Rights Reserved.

Apache Logo