dbertoni 2003/07/02 15:43:34
Modified: c/src/xalanc/PlatformSupport XalanOutputStream.hpp
Log:
Modify write() function to assume buffer has been flushed.
Revision Changes Path
1.2 +6 -4
xml-xalan/c/src/xalanc/PlatformSupport/XalanOutputStream.hpp
Index: XalanOutputStream.hpp
===================================================================
RCS file:
/home/cvs/xml-xalan/c/src/xalanc/PlatformSupport/XalanOutputStream.hpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- XalanOutputStream.hpp 29 Jun 2003 03:57:55 -0000 1.1
+++ XalanOutputStream.hpp 2 Jul 2003 22:43:33 -0000 1.2
@@ -185,7 +185,8 @@
/**
* Write a null-terminated string to the output file. The character
- * will not be transcoded.
+ * will not be transcoded. The caller is responsible for making sure
the
+ * buffer is flushed before calling this member function.
*
* @param theBuffer character buffer to write
*/
@@ -193,6 +194,7 @@
write(const char* theBuffer)
{
assert(theBuffer != 0);
+ assert(m_buffer.empty() == true);
write(theBuffer, length(theBuffer));
}
@@ -211,7 +213,8 @@
/**
* Write a specified number of characters to the output stream. The
string
- * will not be transcoded.
+ * will not be transcoded. The caller is responsible for making sure
the
+ * buffer is flushed before calling this member function.
*
* @param theBuffer character buffer to write
* @param theBufferLength number of characters to write
@@ -222,8 +225,7 @@
size_type theBufferLength)
{
assert(theBuffer != 0);
-
- flushBuffer();
+ assert(m_buffer.empty() == true);
writeData(theBuffer,
theBufferLength);
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]