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(XALANOUTPUTSTREAMPRINTWRITER_HEADER_GUARD_1357924680) 00017 #define XALANOUTPUTSTREAMPRINTWRITER_HEADER_GUARD_1357924680 00018 00019 00020 00021 // Base include file. Must be first. 00022 #include <xalanc/PlatformSupport/PlatformSupportDefinitions.hpp> 00023 00024 00025 00026 #include <xalanc/XalanDOM/XalanDOMString.hpp> 00027 00028 00029 00030 #include <xalanc/PlatformSupport/PrintWriter.hpp> 00031 00032 00033 00034 XALAN_CPP_NAMESPACE_BEGIN 00035 00036 00037 00038 class XalanOutputStream; 00039 00040 00041 00042 class XALAN_PLATFORMSUPPORT_EXPORT XalanOutputStreamPrintWriter : public PrintWriter 00043 { 00044 public: 00045 00052 XalanOutputStreamPrintWriter( 00053 XalanOutputStream& theOutputStream, 00054 bool fAutoFlush = false); 00055 00056 virtual 00057 ~XalanOutputStreamPrintWriter(); 00058 00059 00060 virtual bool 00061 checkError() const; 00062 00063 virtual void 00064 close(); 00065 00066 virtual void 00067 flush(); 00068 00069 virtual XalanOutputStream* 00070 getStream(); 00071 00072 virtual const XalanOutputStream* 00073 getStream() const; 00074 00075 00076 virtual void 00077 write( 00078 const char* s, 00079 size_t theOffset = 0, 00080 size_t theLength = npos); 00081 00082 virtual void 00083 write( 00084 const XalanDOMChar* s, 00085 XalanDOMString::size_type theOffset = 0, 00086 XalanDOMString::size_type theLength = XalanDOMString::npos); 00087 00088 virtual void 00089 write(XalanDOMChar c); 00090 00091 virtual void 00092 write( 00093 const XalanDOMString& s, 00094 XalanDOMString::size_type theOffset = 0, 00095 XalanDOMString::size_type theLength = XalanDOMString::npos); 00096 00097 #if !defined(XALAN_BOOL_AS_INT) 00098 virtual void 00099 print(bool b); 00100 #endif 00101 00102 virtual void 00103 print(char c); 00104 00105 virtual void 00106 print( 00107 const char* s, 00108 size_t theLength = npos); 00109 00110 virtual void 00111 print( 00112 const XalanDOMChar* s, 00113 XalanDOMString::size_type theLength = XalanDOMString::npos); 00114 00115 virtual void 00116 print(double d); 00117 00118 virtual void 00119 print(int i); 00120 00121 virtual void 00122 print(long l); 00123 00124 virtual void 00125 print(const XalanDOMString& s); 00126 00127 virtual void 00128 println(); 00129 00130 #if !defined(XALAN_BOOL_AS_INT) 00131 virtual void 00132 println(bool x); 00133 #endif 00134 00135 virtual void 00136 println(char x); 00137 00138 virtual void 00139 println( 00140 const char* s, 00141 size_t theLength = npos); 00142 00143 virtual void 00144 println( 00145 const XalanDOMChar* s, 00146 XalanDOMString::size_type theLength = XalanDOMString::npos); 00147 00148 virtual void 00149 println(double x); 00150 00151 virtual void 00152 println(int x); 00153 00154 virtual void 00155 println(long x); 00156 00157 virtual void 00158 println(const XalanDOMString& s); 00159 00160 private: 00161 00162 void 00163 flushWideChars(); 00164 00165 00166 // Not implemented 00167 XalanOutputStreamPrintWriter(const XalanOutputStreamPrintWriter&); 00168 00169 XalanOutputStreamPrintWriter& 00170 operator=(const XalanOutputStreamPrintWriter&); 00171 00172 bool 00173 operator==(const XalanOutputStreamPrintWriter&); 00174 00175 // Data members... 00176 XalanOutputStream& m_outputStream; 00177 00178 XalanDOMString m_buffer; 00179 00180 bool m_flushWideChars; 00181 }; 00182 00183 00184 00185 XALAN_CPP_NAMESPACE_END 00186 00187 00188 00189 #endif // XALANOUTPUTSTREAMPRINTWRITER_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.8 |
|