Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.11


PrintWriter.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(PRINTWRITER_HEADER_GUARD_1357924680)
19 #define PRINTWRITER_HEADER_GUARD_1357924680
20 
21 
22 
23 // Base include file. Must be first.
25 
26 
27 
28 // Base class header file.
30 
31 
32 
33 XALAN_CPP_NAMESPACE_BEGIN
34 
35 
36 
38 {
39 public:
40 
41  /**
42  * Constructor
43  *
44  * @param fAutoFlush if true, the output will not be buffered
45  */
46  PrintWriter( bool fAutoFlush = false, MemoryManager& theManager XALAN_DEFAULT_MEMMGR);
47 
48  MemoryManager&
50  {
51  return m_memoryManager;
52  }
53 
54  virtual
56 
57  /**
58  * Flush the stream, then check the error status.
59  *
60  * @return true if no errors
61  */
62  virtual bool
63  checkError() const = 0;
64 
65  // Functions inherited from Writer...
66 
67  virtual void
68  close() = 0;
69 
70  virtual void
71  flush() = 0;
72 
73 
74  // Output functions inherited from Writer...
75 
76  virtual void
78  const char* s,
79  size_t theOffset = 0,
80  size_t theLength = npos) = 0;
81 
82  virtual void
84  const XalanDOMChar* s,
85  XalanDOMString::size_type theOffset = 0,
87 
88  virtual void
89  write(XalanDOMChar c) = 0;
90 
91  virtual void
93  const XalanDOMString& s,
94  XalanDOMString::size_type theOffset = 0,
96 
97  // Output functions which are new...
98 
99 #if !defined(XALAN_BOOL_AS_INT)
100  virtual void
101  print(bool b) = 0;
102 #endif
103 
104  virtual void
105  print(char c) = 0;
106 
107  virtual void
109  const char* s,
110  size_t theLength = npos) = 0;
111 
112  virtual void
114  const XalanDOMChar* s,
116 
117  virtual void
118  print(double d) = 0;
119 
120  virtual void
121  print(int i) = 0;
122 
123  virtual void
124  print(long l) = 0;
125 
126  virtual void
127  print(const XalanDOMString& s) = 0;
128 
129  virtual void
130  println() = 0;
131 
132 #if !defined(XALAN_BOOL_AS_INT)
133  virtual void
134  println(bool b) = 0;
135 #endif
136 
137  virtual void
138  println(char x) = 0;
139 
140  virtual void
142  const char* s,
143  size_t theLength = npos) = 0;
144 
145  virtual void
147  const XalanDOMChar* s,
149 
150  virtual void
151  println(double x) = 0;
152 
153  virtual void
154  println(int x) = 0;
155 
156  virtual void
157  println(long x) = 0;
158 
159  virtual void
160  println(const XalanDOMString& s) = 0;
161 
162 protected:
163 
164  const bool m_fAutoFlush;
165 
166  MemoryManager& m_memoryManager;
167 
168  // Some static strings to help derived classes...
169  static const XalanDOMChar s_trueString[];
170 
171  static const XalanDOMChar s_falseString[];
172 
173  static const XalanDOMChar s_newlineString[];
174 
175 private:
176 
177  // Not implemented
178  PrintWriter(const PrintWriter&);
179 
180  PrintWriter&
181  operator=(const PrintWriter&);
182 
183  bool
184  operator==(const PrintWriter&);
185 };
186 
187 
188 
189 XALAN_CPP_NAMESPACE_END
190 
191 
192 
193 #endif // PRINTWRITER_HEADER_GUARD_1357924680
PrintWriter::close
virtual void close()=0
Close the stream.
PrintWriter::checkError
virtual bool checkError() const =0
Flush the stream, then check the error status.
PrintWriter::println
virtual void println(long x)=0
PrintWriter::write
virtual void write(const char *s, size_t theOffset=0, size_t theLength=npos)=0
Writes a string.
PrintWriter::println
virtual void println(const XalanDOMChar *s, XalanDOMString::size_type theLength=XalanDOMString::npos)=0
Writer.hpp
XalanDOMString::size_type
XalanSize_t size_type
Definition: XalanDOMString.hpp:57
operator==
bool operator==(const ElemAttributeSet &theLHS, const ElemAttributeSet &theRHS)
Definition: ElemAttributeSet.hpp:111
PrintWriter::print
virtual void print(const XalanDOMChar *s, XalanDOMString::size_type theLength=XalanDOMString::npos)=0
PrintWriter::m_memoryManager
MemoryManager & m_memoryManager
Definition: PrintWriter.hpp:166
PrintWriter::print
virtual void print(char c)=0
PrintWriter::write
virtual void write(XalanDOMChar c)=0
Writes a character.
PrintWriter::print
virtual void print(const XalanDOMString &s)=0
PrintWriter::println
virtual void println(double x)=0
XALAN_DEFAULT_MEMMGR
#define XALAN_DEFAULT_MEMMGR
Definition: XalanMemoryManagement.hpp:524
XALAN_PLATFORMSUPPORT_EXPORT
#define XALAN_PLATFORMSUPPORT_EXPORT
Definition: PlatformSupportDefinitions.hpp:35
PlatformSupportDefinitions.hpp
PrintWriter::println
virtual void println(bool b)=0
PrintWriter::~PrintWriter
virtual ~PrintWriter()
PrintWriter::println
virtual void println()=0
PrintWriter::flush
virtual void flush()=0
Flush the stream.
XalanDOMString::npos
@ npos
Definition: XalanDOMString.hpp:67
PrintWriter::println
virtual void println(int x)=0
PrintWriter::println
virtual void println(char x)=0
PrintWriter::PrintWriter
PrintWriter(bool fAutoFlush=false, MemoryManager &theManager XALAN_DEFAULT_MEMMGR)
Constructor.
XalanDOMString
Definition: XalanDOMString.hpp:46
PrintWriter::write
virtual void write(const XalanDOMChar *s, XalanDOMString::size_type theOffset=0, XalanDOMString::size_type theLength=XalanDOMString::npos)=0
Writes a string.
PrintWriter::write
virtual void write(const XalanDOMString &s, XalanDOMString::size_type theOffset=0, XalanDOMString::size_type theLength=XalanDOMString::npos)=0
Writes a string.
PrintWriter::print
virtual void print(int i)=0
PrintWriter::print
virtual void print(bool b)=0
PrintWriter::println
virtual void println(const XalanDOMString &s)=0
PrintWriter::print
virtual void print(double d)=0
Writer
Definition: Writer.hpp:45
PrintWriter::print
virtual void print(const char *s, size_t theLength=npos)=0
PrintWriter
Definition: PrintWriter.hpp:38
PrintWriter::print
virtual void print(long l)=0
PrintWriter::println
virtual void println(const char *s, size_t theLength=npos)=0
PrintWriter::getMemoryManager
MemoryManager & getMemoryManager()
Definition: PrintWriter.hpp:49
PrintWriter::m_fAutoFlush
const bool m_fAutoFlush
Definition: PrintWriter.hpp:164

Interpreting class diagrams

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

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

Apache Logo