Xalan-C++ API Reference  1.12.0
DOMServices.hpp
Go to the documentation of this file.
1 /*
2  * Licensed to the Apache Software Foundation (ASF) under one
3  * or more contributor license agreements. See the NOTICE file
4  * distributed with this work for additional information
5  * regarding copyright ownership. The ASF licenses this file
6  * to you under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */
18 #if !defined(DOMSERVICES_HEADER_GUARD_1357924680)
19 #define DOMSERVICES_HEADER_GUARD_1357924680
20 
21 
22 
23 // Base include file. Must be first.
25 
26 
27 
35 
36 
37 
41 
42 
43 
45 
46 
47 
48 class XalanDocument;
50 
51 
52 
54 {
55 public:
56 
57  static const XalanDOMString& s_XMLString;
65 
74 
75 
76  // A dummy string to return when we need an emtpy string...
78 
79 
80  /**
81  * Initialize static data. Must be called before any
82  * other functions are called.
83  */
84  static void
85  initialize(MemoryManager& theManager);
86 
87  /**
88  * Destroy static data. After thus function is called,
89  * no other functions can be called.
90  */
91  static void
92  terminate();
93 
94 
95  /**
96  * Retrieves data for node
97  *
98  * @param node DOM node whose data is to be returned
99  * @param data a string to which the node's data will be appended
100  */
101  static void
102  getNodeData(
103  const XalanNode& node,
104  XalanDOMString& data);
105 
106  /**
107  * Retrieves data for node
108  *
109  * @param node DOM node whose data is to be returned
110  * @param context The current execution context
111  * @param data a string to which the node's data will be appended
112  */
113  static void
115  const XalanNode& node,
116  ExecutionContext& context,
117  XalanDOMString& data)
118  {
119  if (!context.hasPreserveOrStripSpaceConditions())
120  {
121  getNodeData(node, data);
122  }
123  else
124  {
125  doGetNodeData(node, context, data);
126  }
127  }
128 
129 
130 
131  /**
132  * Retrieves data for node
133  *
134  * @param attribute DOM node whose data is to be returned
135  * @param data a string to which the node's data will be appended
136  */
137  static void
139  const XalanAttr& attribute,
140  XalanDOMString& data)
141  {
142  data.append(attribute.getNodeValue());
143  }
144 
145 
146 
147  /**
148  * Retrieves data for node
149  *
150  * @param comment DOM node whose data is to be returned
151  * @param data a string to which the node's data will be appended
152  */
153  static void
155  const XalanComment& comment,
156  XalanDOMString& data)
157  {
158  data.append(comment.getData());
159  }
160 
161  /**
162  * Retrieves data for node
163  *
164  * @param document DOM node whose data is to be returned
165  * @param data a string to which the node's data will be appended
166  */
167  static void
168  getNodeData(
169  const XalanDocument& document,
170  XalanDOMString& data);
171 
172  /**
173  * Retrieves data for node
174  *
175  * @param document The DOM node whose data is to be returned
176  * @param context The current execution context
177  * @param data a string to which the node's data will be appended
178  */
179  static void
181  const XalanDocument& document,
182  ExecutionContext& context,
183  XalanDOMString& data)
184  {
185  if (!context.hasPreserveOrStripSpaceConditions())
186  {
187  getNodeData(document, data);
188  }
189  else
190  {
191  doGetNodeData(document, context, data);
192  }
193  }
194 
195  /**
196  * Retrieves data for node
197  *
198  * @param documentFragment The DOM node whose data is to be returned
199  * @param data a string to which the node's data will be appended
200  */
201  static void
202  getNodeData(
203  const XalanDocumentFragment& documentFragment,
204  XalanDOMString& data);
205 
206  /**
207  * Retrieves data for node
208  *
209  * @param documentFragment The DOM node whose data is to be returned
210  * @param context The current execution context
211  * @param data a string to which the node's data will be appended
212  */
213  static void
215  const XalanDocumentFragment& documentFragment,
216  ExecutionContext& context,
217  XalanDOMString& data)
218  {
219  if (!context.hasPreserveOrStripSpaceConditions())
220  {
221  getNodeData(documentFragment, data);
222  }
223  else
224  {
225  doGetNodeData(documentFragment, context, data);
226  }
227  }
228 
229  /**
230  * Retrieves data for node
231  *
232  * @param element DOM node whose data is to be returned
233  * @param data a string to which the node's data will be appended
234  */
235  static void
236  getNodeData(
237  const XalanElement& element,
238  XalanDOMString& data);
239 
240  /**
241  * Retrieves data for node
242  *
243  * @param node DOM node whose data is to be returned
244  * @param context The current execution context
245  * @param data a string to which the node's data will be appended
246  */
247  static void
249  const XalanElement& element,
250  ExecutionContext& context,
251  XalanDOMString& data)
252  {
253  if (!context.hasPreserveOrStripSpaceConditions())
254  {
255  getNodeData(element, data);
256  }
257  else
258  {
259  doGetNodeData(element, context, data);
260  }
261  }
262 
263  /**
264  * Retrieves data for node
265  *
266  * @param pi DOM node whose data is to be returned
267  * @param data a string to which the node's data will be appended
268  */
269  static void
271  const XalanProcessingInstruction& pi,
272  XalanDOMString& data)
273  {
274  data.append(pi.getData());
275  }
276 
277  /**
278  * Retrieves data for node
279  *
280  * @param node DOM node whose data is to be returned
281  * @param data a string to which the node's data will be appended
282  */
283  static void
285  const XalanText& text,
286  XalanDOMString& data)
287  {
288  data.append(text.getData());
289  }
290 
291  /**
292  * Retrieves data for node
293  *
294  * @param text DOM node whose data is to be returned
295  * @param context The current execution context
296  * @param data a string to which the node's data will be appended
297  */
298  static void
300  const XalanText& text,
301  ExecutionContext& context,
302  XalanDOMString& data)
303  {
304  if (!context.hasPreserveOrStripSpaceConditions())
305  {
306  getNodeData(text, data);
307  }
308  else
309  {
310  doGetNodeData(text, context, data);
311  }
312  }
313 
314  typedef void (FormatterListener::*MemberFunctionPtr)(const XMLCh* const, const FormatterListener::size_type);
315 
316  /**
317  * Sends the data for a node to a FormatterListener
318  *
319  * @param node DOM node whose data is to be returned
320  * @param formatterListener the FormatterListener instance to receive the data
321  * @param function A pointer to the member function of FormatterListener to call
322  */
323  static void
324  getNodeData(
325  const XalanNode& node,
326  FormatterListener& formatterListener,
327  MemberFunctionPtr function);
328 
329  /**
330  * Sends the data for a node to a FormatterListener
331  *
332  * @param node DOM node whose data is to be returned
333  * @param context The current execution context
334  * @param formatterListener the FormatterListener instance to receive the data
335  * @param function A pointer to the member function of FormatterListener to call
336  */
337  static void
339  const XalanNode& node,
340  ExecutionContext& context,
341  FormatterListener& formatterListener,
342  MemberFunctionPtr function)
343  {
344  if (!context.hasPreserveOrStripSpaceConditions())
345  {
346  getNodeData(node, formatterListener, function);
347  }
348  else
349  {
350  doGetNodeData(node, context, formatterListener, function);
351  }
352  }
353 
354  /**
355  * Sends the data for a node to a FormatterListener
356  *
357  * @param attribute DOM node whose data is to be returned
358  * @param formatterListener the FormatterListener instance to receive the data
359  * @param fRaw Whether or not the data should be sent raw.
360  */
361  static void
363  const XalanAttr& attribute,
364  FormatterListener& formatterListener,
365  MemberFunctionPtr function)
366  {
367  sendData(formatterListener, function, attribute.getNodeValue());
368  }
369 
370  /**
371  * Sends the data for a node to a FormatterListener
372  *
373  * @param comment DOM node whose data is to be returned
374  * @param formatterListener the FormatterListener instance to receive the data
375  * @param fRaw Whether or not the data should be sent raw.
376  */
377  static void
379  const XalanComment& comment,
380  FormatterListener& formatterListener,
381  MemberFunctionPtr function)
382  {
383  sendData(formatterListener, function, comment.getData());
384  }
385 
386  /**
387  * Sends the data for a node to a FormatterListener
388  *
389  * @param document DOM node whose data is to be returned
390  * @param formatterListener the FormatterListener instance to receive the data
391  * @param fRaw Whether or not the data should be sent raw.
392  */
393  static void
394  getNodeData(
395  const XalanDocument& document,
396  FormatterListener& formatterListener,
397  MemberFunctionPtr function);
398 
399  /**
400  * Sends the data for a node to a FormatterListener
401  *
402  * @param node DOM node whose data is to be returned
403  * @param context The current execution context
404  * @param formatterListener the FormatterListener instance to receive the data
405  * @param function A pointer to the member function of FormatterListener to call
406  */
407  static void
409  const XalanDocument& document,
410  ExecutionContext& context,
411  FormatterListener& formatterListener,
412  MemberFunctionPtr function)
413  {
414  if (!context.hasPreserveOrStripSpaceConditions())
415  {
416  getNodeData(document, formatterListener, function);
417  }
418  else
419  {
420  doGetNodeData(document, context, formatterListener, function);
421  }
422  }
423 
424  /**
425  * Sends the data for a node to a FormatterListener
426  *
427  * @param documentFragment DOM node whose data is to be sent
428  * @param formatterListener the FormatterListener instance to receive the data
429  * @param fRaw Whether or not the data should be sent raw.
430  */
431  static void
432  getNodeData(
433  const XalanDocumentFragment& documentFragment,
434  FormatterListener& formatterListener,
435  MemberFunctionPtr function);
436 
437  /**
438  * Sends the data for a node to a FormatterListener
439  *
440  * @param documentFragment DOM node whose data is to be sent
441  * @param context The current execution context
442  * @param formatterListener the FormatterListener instance to receive the data
443  * @param fRaw Whether or not the data should be sent raw.
444  */
445  static void
447  const XalanDocumentFragment& documentFragment,
448  ExecutionContext& context,
449  FormatterListener& formatterListener,
450  MemberFunctionPtr function)
451  {
452  if (!context.hasPreserveOrStripSpaceConditions())
453  {
454  getNodeData(documentFragment, formatterListener, function);
455  }
456  else
457  {
458  doGetNodeData(documentFragment, context, formatterListener, function);
459  }
460  }
461 
462  /**
463  * Sends the data for a node to a FormatterListener
464  *
465  * @param element DOM node whose data is to be returned
466  * @param formatterListener the FormatterListener instance to receive the data
467  * @param fRaw Whether or not the data should be sent raw.
468  */
469  static void
470  getNodeData(
471  const XalanElement& element,
472  FormatterListener& formatterListener,
473  MemberFunctionPtr function);
474 
475  /**
476  * Sends the data for a node to a FormatterListener
477  *
478  * @param node DOM node whose data is to be returned
479  * @param context The current execution context
480  * @param formatterListener the FormatterListener instance to receive the data
481  * @param function A pointer to the member function of FormatterListener to call
482  */
483  static void
485  const XalanElement& element,
486  ExecutionContext& context,
487  FormatterListener& formatterListener,
488  MemberFunctionPtr function)
489  {
490  if (!context.hasPreserveOrStripSpaceConditions())
491  {
492  getNodeData(element, formatterListener, function);
493  }
494  else
495  {
496  doGetNodeData(element, context, formatterListener, function);
497  }
498  }
499 
500  /**
501  * Sends the data for a node to a FormatterListener
502  *
503  * @param pi DOM node whose data is to be returned
504  * @param formatterListener the FormatterListener instance to receive the data
505  * @param fRaw Whether or not the data should be sent raw.
506  */
507  static void
509  const XalanProcessingInstruction& pi,
510  FormatterListener& formatterListener,
511  MemberFunctionPtr function)
512  {
513  sendData(formatterListener, function, pi.getData());
514  }
515 
516  /**
517  * Sends the data for a node to a FormatterListener
518  *
519  * @param node DOM node whose data is to be returned
520  * @param formatterListener the FormatterListener instance to receive the data
521  * @param fRaw Whether or not the data should be sent raw.
522  */
523  static void
525  const XalanText& text,
526  FormatterListener& formatterListener,
527  MemberFunctionPtr function)
528  {
529  sendData(formatterListener, function, text.getData());
530  }
531 
532  /**
533  * Sends the data for a node to a FormatterListener
534  *
535  * @param node DOM node whose data is to be returned
536  * @param context The current execution context
537  * @param formatterListener the FormatterListener instance to receive the data
538  * @param fRaw Whether or not the data should be sent raw.
539  */
540  static void
542  const XalanText& text,
543  ExecutionContext& context,
544  FormatterListener& formatterListener,
545  MemberFunctionPtr function)
546  {
547  if (!context.hasPreserveOrStripSpaceConditions())
548  {
549  getNodeData(text, formatterListener, function);
550  }
551  else
552  {
553  doGetNodeData(text, context, formatterListener, function);
554  }
555  }
556 
557  /**
558  * Retrieve the name of the node, taking into
559  * account the differences between the DOM and
560  * XSLT data models.
561  *
562  * @param node DOM node whose name is returned
563  * @return name of the node
564  */
565  static const XalanDOMString&
566  getNameOfNode(const XalanNode& n);
567 
568  /**
569  * Retrieve the name of the node, taking into
570  * account the differences between the DOM and
571  * XSLT data models.
572  *
573  * @param attr DOM attribute node whose name is returned
574  * @return name of the node
575  */
576  static const XalanDOMString&
578  {
579  const XalanDOMString& theName = attr.getNodeName();
580 
581  if (startsWith(theName, s_XMLNamespaceWithSeparator) == true)
582  {
583  // Special case for namespace nodes...
584  return attr.getLocalName();
585  }
586  else if (equals(theName, s_XMLNamespace) == true)
587  {
588  return s_emptyString;
589  }
590  else
591  {
592  return theName;
593  }
594  }
595 
596  /**
597  * Retrieve the name of the node, taking into
598  * account the differences between the DOM and
599  * XSLT data models.
600  *
601  * @param attr DOM element node whose name is returned
602  * @return name of the node
603  */
604  static const XalanDOMString&
605  getNameOfNode(const XalanElement& element)
606  {
607  return element.getNodeName();
608  }
609 
610  /**
611  * Retrieve local name of node, taking into
612  * account the differences between the DOM and
613  * XSLT data models.
614  *
615  * @param node DOM node whose name is returned
616  * @return name of node without namespace
617  */
618  static const XalanDOMString&
620  {
621  const XalanDOMString& theLocalName = n.getLocalName();
622 
623  if (theLocalName.empty() == false)
624  {
625  return theLocalName;
626  }
627  else
628  {
629  return n.getNodeName();
630  }
631  }
632 
633  /**
634  * Retrieve the namespace of the node, taking into
635  * account the differences between the DOM and
636  * XSLT data models.
637  *
638  * @param node DOM node whose namespace is returned
639  * @return namespace of the node
640  */
641  static const XalanDOMString&
642  getNamespaceOfNode(const XalanNode& n);
643 
644  /**
645  * Determine whether or not an attribute node
646  * is declaring a namespace.
647  *
648  * @param node DOM node to check
649  * @return true if the attribute is declaring a namespace, false if not.
650  */
651  static bool
653  {
654  const XalanDOMString& theName = n.getNodeName();
655 
656  return startsWith(theName, DOMServices::s_XMLNamespaceWithSeparator) == true ||
657  equals(theName, DOMServices::s_XMLNamespace) == true;
658  }
659 
660  /**
661  * Retrieve the parent of a node. This function has to be implemented,
662  * because the DOM WG decided that attributes don't have parents.
663  *
664  * @param node child node
665  * @return parent node
666  */
667  static XalanNode*
669  {
670  if(node.getNodeType() == XalanNode::ATTRIBUTE_NODE)
671  {
672  return static_cast<const XalanAttr&>(node).getOwnerElement();
673  }
674  else
675  {
676  return node.getParentNode();
677  }
678  }
679 
680  /**
681  * Retrieve the URI corresponding to a namespace prefix
682  *
683  * @param prefix prefix for a namespace
684  * @param namespaceContext DOM element representing the context for namespace
685  * @return URI corresponding to namespace
686  */
687  static const XalanDOMString*
688  getNamespaceForPrefix(
689  const XalanDOMString& prefix,
690  const XalanElement& namespaceContext);
691 
692  /**
693  * Retrieve the URI corresponding to a namespace prefix, using the supplied
694  * name, and PrefixResolver. The routine also returns the prefix.
695  *
696  * @param theName The name that contains the prefix
697  * @param thePrefixResolver The PrefixResolver to use
698  * @param isAttribute If true, special rules for attributes are used
699  * @param thePrefix The prefix
700  * @return URI corresponding to namespace
701  */
702  static const XalanDOMString*
703  getNamespaceForPrefix(
704  const XalanDOMChar* theName,
705  const PrefixResolver& thePrefixResolver,
706  bool isAttribute,
707  XalanDOMString& thePrefix);
708 
709  /**
710  * Determine if a node is after another node, in document order.
711  *
712  * @param node1 The first node
713  * @param node2 The second node
714  * @return true if node1 one is after node2, or false if it is not.
715  */
716  static bool
717  isNodeAfter(
718  const XalanNode& node1,
719  const XalanNode& node2);
720 
721  /**
722  * Determine if a node is after another node in the sibling list.
723  *
724  * @param parent The parent of the nodes.
725  * @param node1 The first node
726  * @param node2 The second node
727  * @return true if node1 one is after node2, or false if it is not.
728  */
729  static bool
730  isNodeAfterSibling(
731  const XalanNode& parent,
732  const XalanNode& child1,
733  const XalanNode& child2);
734 
735 private:
736 
737  friend void
738  getChildData(
739  const XalanNode* child,
740  XalanDOMString& data);
741 
742  friend void
743  getChildData(
744  const XalanNode* child,
745  ExecutionContext& executionContext,
746  XalanDOMString& data);
747 
748  friend void
749  getChildData(
750  const XalanNode* child,
751  FormatterListener& formatterListener,
752  DOMServices::MemberFunctionPtr function);
753 
754  /**
755  * Retrieves data for node
756  *
757  * @param node DOM node whose data is to be returned
758  * @param context The current execution context
759  * @param data a string to which the node's data will be appended
760  */
761  static void
762  doGetNodeData(
763  const XalanNode& node,
764  ExecutionContext& executionContext,
765  XalanDOMString& data);
766 
767  /**
768  * Retrieves data for node
769  *
770  * @param document DOM node whose data is to be returned
771  * @param context The current execution context
772  * @param data a string to which the node's data will be appended
773  */
774  static void
775  doGetNodeData(
776  const XalanDocument& document,
777  ExecutionContext& context,
778  XalanDOMString& data);
779 
780  /**
781  * Retrieves data for node
782  *
783  * @param documentFragment DOM node whose data is to be returned
784  * @param context The current execution context
785  * @param data a string to which the node's data will be appended
786  */
787  static void
788  doGetNodeData(
789  const XalanDocumentFragment& documentFragment,
790  ExecutionContext& context,
791  XalanDOMString& data);
792 
793  /**
794  * Retrieves data for node
795  *
796  * @param element DOM node whose data is to be returned
797  * @param context The current execution context
798  * @param data a string to which the node's data will be appended
799  */
800  static void
801  doGetNodeData(
802  const XalanElement& element,
803  ExecutionContext& context,
804  XalanDOMString& data);
805 
806  /**
807  * Retrieves data for node
808  *
809  * @param node DOM node whose data is to be returned
810  * @param context The current execution context
811  * @param data a string to which the node's data will be appended
812  */
813  static void
814  doGetNodeData(
815  const XalanText& text,
816  ExecutionContext& context,
817  XalanDOMString& data)
818  {
819  assert(context.hasPreserveOrStripSpaceConditions() == true);
820 
821  if (context.shouldStripSourceNode(text) == false)
822  {
823  data.append(text.getData());
824  }
825  }
826 
827  /**
828  * Sends the data for a node to a FormatterListener
829  *
830  * @param node DOM node whose data is to be returned
831  * @param context The current execution context
832  * @param formatterListener the FormatterListener instance to receive the data
833  * @param function A pointer to the member function of FormatterListener to call
834  */
835  static void
836  doGetNodeData(
837  const XalanNode& node,
838  ExecutionContext& context,
839  FormatterListener& formatterListener,
840  MemberFunctionPtr function);
841 
842  /**
843  * Sends the data for a node to a FormatterListener
844  *
845  * @param node DOM node whose data is to be returned
846  * @param context The current execution context
847  * @param formatterListener the FormatterListener instance to receive the data
848  * @param function A pointer to the member function of FormatterListener to call
849  */
850  static void
851  doGetNodeData(
852  const XalanDocument& document,
853  ExecutionContext& context,
854  FormatterListener& formatterListener,
855  MemberFunctionPtr function);
856 
857  /**
858  * Sends the data for a node to a FormatterListener
859  *
860  * @param documentFragment DOM node whose data is to be sent
861  * @param context The current execution context
862  * @param formatterListener the FormatterListener instance to receive the data
863  * @param fRaw Whether or not the data should be sent raw.
864  */
865  static void
866  doGetNodeData(
867  const XalanDocumentFragment& documentFragment,
868  ExecutionContext& context,
869  FormatterListener& formatterListener,
870  MemberFunctionPtr function);
871 
872  /**
873  * Sends the data for a node to a FormatterListener
874  *
875  * @param node DOM node whose data is to be returned
876  * @param context The current execution context
877  * @param formatterListener the FormatterListener instance to receive the data
878  * @param function A pointer to the member function of FormatterListener to call
879  */
880  static void
881  doGetNodeData(
882  const XalanElement& element,
883  ExecutionContext& context,
884  FormatterListener& formatterListener,
885  MemberFunctionPtr function);
886 
887  /**
888  * Sends the data for a node to a FormatterListener
889  *
890  * @param node DOM node whose data is to be returned
891  * @param context The current execution context
892  * @param formatterListener the FormatterListener instance to receive the data
893  * @param fRaw Whether or not the data should be sent raw.
894  */
895  static void
896  doGetNodeData(
897  const XalanText& text,
898  ExecutionContext& context,
899  FormatterListener& formatterListener,
900  MemberFunctionPtr function)
901  {
902  assert(context.hasPreserveOrStripSpaceConditions() == true);
903 
904  if (context.shouldStripSourceNode(text) == false)
905  {
906  sendData(formatterListener, function, text.getData());
907  }
908  }
909 
910  /**
911  * Utility function to send data to a FormatterListener
912  *
913  * @param formatterListener The FormatterListener instance.
914  * @param fRaw Whether or not the data should be sent raw.
915  * @param data The data to send.
916  */
917  static void
918  sendData(
919  FormatterListener& formatterListener,
920  MemberFunctionPtr function,
921  const XalanDOMString& data)
922  {
923  const XalanDOMString::size_type theLength =
924  data.length();
925 
926  if (theLength != 0)
927  {
928  assert(theLength == FormatterListener::size_type(theLength));
929 
930  (formatterListener.*function)(
931  data.c_str(),
932  FormatterListener::size_type(theLength));
933  }
934  }
935 };
936 
937 
938 
939 }
940 
941 
942 
943 #endif // DOMSERVICES_HEADER_GUARD_1357924680
XalanProcessingInstruction.hpp
xalanc::XalanText::getData
virtual const XalanDOMString & getData() const =0
Returns the character data of the node that implements this interface.
xalanc::DOMServices::s_emptyString
static const XalanDOMString s_emptyString
Definition: DOMServices.hpp:77
xalanc::DOMServices::s_XMLNamespaceURILength
static const XalanDOMString::size_type & s_XMLNamespaceURILength
Definition: DOMServices.hpp:69
xalanc::DOMServices::s_XMLNamespacePrefixLength
static const XalanDOMString::size_type & s_XMLNamespacePrefixLength
Definition: DOMServices.hpp:68
ExecutionContext.hpp
XALAN_DOMSUPPORT_EXPORT
#define XALAN_DOMSUPPORT_EXPORT
Definition: DOMSupportDefinitions.hpp:35
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanAttr &attribute, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:138
xalanc::XalanComment
Definition: XalanComment.hpp:32
XALAN_CPP_NAMESPACE
#define XALAN_CPP_NAMESPACE
Xalan-C++ namespace, including major and minor version.
Definition: XalanVersion.hpp:76
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanProcessingInstruction &pi, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:508
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanNode &node, ExecutionContext &context, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:338
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanComment &comment, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:378
XalanText.hpp
xalanc::XalanAttr::getNodeName
virtual const XalanDOMString & getNodeName() const =0
Gets the name of this node, depending on its type.
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanText &text, ExecutionContext &context, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:299
xalanc::XalanNode
Definition: XalanNode.hpp:38
xalanc::DOMServices::s_XMLNamespacePrefixURILength
static const XalanDOMString::size_type & s_XMLNamespacePrefixURILength
Definition: DOMServices.hpp:73
XalanElement.hpp
xalanc::XalanElement::getNodeName
virtual const XalanDOMString & getNodeName() const =0
Gets the name of this node, depending on its type.
XalanDOMString.hpp
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanDocumentFragment &documentFragment, ExecutionContext &context, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:446
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanNode &node, ExecutionContext &context, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:114
xalanc::XalanText
Definition: XalanText.hpp:40
xalanc::XalanProcessingInstruction::getData
virtual const XalanDOMString & getData() const =0
The content of this processing instruction.
XalanComment.hpp
FormatterListener.hpp
xalanc::size_type
size_t size_type
Definition: XalanMap.hpp:46
xalanc::XalanDocument
Definition: XalanDocument.hpp:36
xalanc::DOMServices::s_XMLNamespaceSeparatorString
static const XalanDOMString & s_XMLNamespaceSeparatorString
Definition: DOMServices.hpp:63
xalanc::XalanDOMString::empty
bool empty() const
Definition: XalanDOMString.hpp:304
xalanc::XalanDOMString::append
XalanDOMString & append(const XalanDOMString &theSource)
Definition: XalanDOMString.hpp:484
xalanc::XalanNode::getNodeName
virtual const XalanDOMString & getNodeName() const =0
Gets the name of this node, depending on its type.
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanDocumentFragment &documentFragment, ExecutionContext &context, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:214
XalanAttr.hpp
xalanc::DOMServices::s_XMLNamespacePrefix
static const XalanDOMString & s_XMLNamespacePrefix
Definition: DOMServices.hpp:59
xalanc::XalanNode::getLocalName
virtual const XalanDOMString & getLocalName() const =0
Returns the local part of the qualified name of this node.
xalanc::equals
equals(const XalanDOMChar *theLHS, const XalanDOMChar *theRHS, XalanDOMString::size_type theLength)
Compare the contents of two arrays for equality.
xalanc::DOMServices::s_XMLNamespacePrefixURI
static const XalanDOMString & s_XMLNamespacePrefixURI
Definition: DOMServices.hpp:64
xalanc::DOMServices::s_XMLNamespace
static const XalanDOMString & s_XMLNamespace
Definition: DOMServices.hpp:61
xalanc::DOMServices::s_XMLNamespaceLength
static const XalanDOMString::size_type & s_XMLNamespaceLength
Definition: DOMServices.hpp:70
xalanc::DOMServices::s_XMLNamespaceWithSeparatorLength
static const XalanDOMString::size_type & s_XMLNamespaceWithSeparatorLength
Definition: DOMServices.hpp:71
xalanc::DOMServices::s_XMLStringWithSeparator
static const XalanDOMString & s_XMLStringWithSeparator
Definition: DOMServices.hpp:58
DOMStringHelper.hpp
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanText &text, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:284
xalanc::DOMServices::getLocalNameOfNode
static const XalanDOMString & getLocalNameOfNode(const XalanNode &n)
Retrieve local name of node, taking into account the differences between the DOM and XSLT data models...
Definition: DOMServices.hpp:619
xalanc::DOMServices::s_XMLString
static const XalanDOMString & s_XMLString
Definition: DOMServices.hpp:57
xalanc::XalanNode::getNodeType
virtual NodeType getNodeType() const =0
An enum value representing the type of the underlying object.
xalanc::XalanAttr::getLocalName
virtual const XalanDOMString & getLocalName() const =0
Returns the local part of the qualified name of this node.
xalanc::DOMServices::s_XMLNamespaceURI
static const XalanDOMString & s_XMLNamespaceURI
Definition: DOMServices.hpp:60
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanText &text, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:524
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanText &text, ExecutionContext &context, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:541
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanAttr &attribute, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:362
xalanc::XalanAttr
Definition: XalanAttr.hpp:40
xalanc::DOMServices
Definition: DOMServices.hpp:53
xalanc::ExecutionContext::shouldStripSourceNode
virtual bool shouldStripSourceNode(const XalanText &node)=0
Determine if a text node should be stripped from the source tree, as if it weren't there.
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanElement &element, ExecutionContext &context, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:484
xalanc::XalanAttr::getNodeValue
virtual const XalanDOMString & getNodeValue() const =0
Gets the value of this node, depending on its type.
xalanc::DOMServices::s_XMLStringWithSeparatorLength
static const XalanDOMString::size_type & s_XMLStringWithSeparatorLength
Definition: DOMServices.hpp:67
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanComment &comment, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:154
xalanc::DOMServices::s_XMLNamespaceWithSeparator
static const XalanDOMString & s_XMLNamespaceWithSeparator
Definition: DOMServices.hpp:62
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanElement &element, ExecutionContext &context, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:248
xalanc::DOMServices::getNameOfNode
static const XalanDOMString & getNameOfNode(const XalanAttr &attr)
Retrieve the name of the node, taking into account the differences between the DOM and XSLT data mode...
Definition: DOMServices.hpp:577
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanDocument &document, ExecutionContext &context, FormatterListener &formatterListener, MemberFunctionPtr function)
Sends the data for a node to a FormatterListener.
Definition: DOMServices.hpp:408
xalanc::ExecutionContext
Definition: ExecutionContext.hpp:60
xalanc::DOMServices::s_XMLNamespaceSeparatorStringLength
static const XalanDOMString::size_type & s_XMLNamespaceSeparatorStringLength
Definition: DOMServices.hpp:72
xalanc::DOMServices::isNamespaceDeclaration
static bool isNamespaceDeclaration(const XalanAttr &n)
Determine whether or not an attribute node is declaring a namespace.
Definition: DOMServices.hpp:652
XalanDocument.hpp
xalanc::PrefixResolver
This class defines an interface for classes that resolve namespace prefixes to their URIs.
Definition: PrefixResolver.hpp:39
xalanc::XalanComment::getData
virtual const XalanDOMString & getData() const =0
Returns the character data of the node that implements this interface.
xalanc::startsWith
startsWith(const XalanDOMChar *theString, XalanDOMString::size_type theStringLength, const XalanDOMChar *theSubstring, XalanDOMString::size_type theSubstringLength)
Simulates the java String method startsWith().
xalanc::DOMServices::getParentOfNode
static XalanNode * getParentOfNode(const XalanNode &node)
Retrieve the parent of a node.
Definition: DOMServices.hpp:668
DOMSupportDefinitions.hpp
xalanc::ExecutionContext::hasPreserveOrStripSpaceConditions
bool hasPreserveOrStripSpaceConditions() const
Definition: ExecutionContext.hpp:87
xalanc::DOMServices::s_XMLStringLength
static const XalanDOMString::size_type & s_XMLStringLength
Definition: DOMServices.hpp:66
xalanc::XalanElement
Definition: XalanElement.hpp:44
xalanc::FormatterListener
A SAX-based formatter interface for the XSL processor.
Definition: FormatterListener.hpp:56
xalanc::XalanDOMString::size_type
XalanSize_t size_type
Definition: XalanDOMString.hpp:57
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanDocument &document, ExecutionContext &context, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:180
xalanc::XalanNode::getParentNode
virtual XalanNode * getParentNode() const =0
Gets the parent of this node.
xalanc::XalanDOMString
Definition: XalanDOMString.hpp:45
xalanc::DOMServices::getNameOfNode
static const XalanDOMString & getNameOfNode(const XalanElement &element)
Retrieve the name of the node, taking into account the differences between the DOM and XSLT data mode...
Definition: DOMServices.hpp:605
xalanc::XalanDocumentFragment
Definition: XalanDocumentFragment.hpp:32
xalanc::DOMServices::getNodeData
static void getNodeData(const XalanProcessingInstruction &pi, XalanDOMString &data)
Retrieves data for node.
Definition: DOMServices.hpp:270
xalanc::XalanProcessingInstruction
Definition: XalanProcessingInstruction.hpp:32