00001 /* 00002 * Copyright 1999-2004 The Apache Software Foundation. 00003 * 00004 * Licensed under the Apache License, Version 2.0 (the "License"); 00005 * you may not use this file except in compliance with the License. 00006 * You may obtain a copy of the License at 00007 * 00008 * http://www.apache.org/licenses/LICENSE-2.0 00009 * 00010 * Unless required by applicable law or agreed to in writing, software 00011 * distributed under the License is distributed on an "AS IS" BASIS, 00012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00013 * See the License for the specific language governing permissions and 00014 * limitations under the License. 00015 */ 00016 #if !defined(FORMATTERSTRINGLENGTHCOUNTER_HEADER_GUARD_1357924680) 00017 #define FORMATTERSTRINGLENGTHCOUNTER_HEADER_GUARD_1357924680 00018 00019 00020 00021 // Base include file. Must be first. 00022 #include <xalanc/XPath/XPathDefinitions.hpp> 00023 00024 00025 00026 // Base class header file. 00027 #include <xalanc/PlatformSupport/FormatterListener.hpp> 00028 00029 00030 00031 XALAN_CPP_NAMESPACE_BEGIN 00032 00033 00034 00040 class XALAN_XPATH_EXPORT FormatterStringLengthCounter : public FormatterListener 00041 { 00042 public: 00043 00044 typedef unsigned long size_type; 00045 00049 explicit 00050 FormatterStringLengthCounter(); 00051 00052 virtual 00053 ~FormatterStringLengthCounter(); 00054 00055 00056 size_type 00057 getCount() const 00058 { 00059 return m_count; 00060 } 00061 00062 // These methods are inherited from FormatterListener ... 00063 00064 virtual void 00065 setDocumentLocator(const LocatorType* const locator); 00066 00067 virtual void 00068 startDocument(); 00069 00070 virtual void 00071 endDocument(); 00072 00073 virtual void 00074 startElement( 00075 const XMLCh* const name, 00076 AttributeListType& attrs); 00077 00078 virtual void 00079 endElement(const XMLCh* const name); 00080 00081 virtual void 00082 characters( 00083 const XMLCh* const chars, 00084 const unsigned int length); 00085 00086 virtual void 00087 charactersRaw( 00088 const XMLCh* const chars, 00089 const unsigned int length); 00090 00091 virtual void 00092 entityReference(const XMLCh* const name); 00093 00094 virtual void 00095 ignorableWhitespace( 00096 const XMLCh* const chars, 00097 const unsigned int length); 00098 00099 virtual void 00100 processingInstruction( 00101 const XMLCh* const target, 00102 const XMLCh* const data); 00103 00104 virtual void 00105 resetDocument(); 00106 00107 virtual void 00108 comment(const XMLCh* const data); 00109 00110 virtual void 00111 cdata( 00112 const XMLCh* const ch, 00113 const unsigned int length); 00114 00115 private: 00116 00117 // These are not implemented. 00118 FormatterStringLengthCounter(const FormatterStringLengthCounter&); 00119 00120 FormatterStringLengthCounter& 00121 operator=(const FormatterStringLengthCounter&); 00122 00123 bool 00124 operator==(const FormatterStringLengthCounter&) const; 00125 00126 // Data members... 00127 size_type m_count; 00128 }; 00129 00130 00131 00132 XALAN_CPP_NAMESPACE_END 00133 00134 00135 00136 #endif // FORMATTERSTRINGLENGTHCOUNTER_HEADER_GUARD_1357924680
Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.
Xalan-C++ XSLT Processor Version 1.10 |
|