com.plumtree.openfoundation.io
Class XPBufferedWriter

java.lang.Object
  extended bycom.plumtree.openfoundation.io.XPWriter
      extended bycom.plumtree.openfoundation.io.XPBufferedWriter

public class XPBufferedWriter
extends XPWriter

Corresponds to java.io.BufferedWriter or System.IO.TextWriter.


Field Summary
 
Fields inherited from class com.plumtree.openfoundation.io.XPWriter
writer
 
Constructor Summary
XPBufferedWriter(java.io.BufferedWriter bufferedWriter)
          Creates a new XPBufferedWriter that wraps the BufferedWriter.
XPBufferedWriter(java.io.Writer writer)
          Constructs a XPBufferedWriter object.
XPBufferedWriter(XPWriter drain)
          Constructs a XPBufferedWriter object.
 
Method Summary
 java.io.BufferedWriter GetUnderlyingObject()
          Returns the underlying platform-specific instance for framework use.
 void WriteLine(char[] buffer)
          Writes an array of characters, followed by a line terminator to the stream.
 void WriteLine(int b)
          Writes a single character, followed by a line terminator to the stream.
 void WriteLine(java.lang.String line)
          Writes a string, followed by a line terminator to the stream.
 void WriteLine(java.lang.String buffer, int offset, int count)
          Writes a portion of a string, followed by a line terminator to the stream.
 
Methods inherited from class com.plumtree.openfoundation.io.XPWriter
Close, Flush, NullWriter, Write, Write, Write, Write, WriteLine
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XPBufferedWriter

public XPBufferedWriter(XPWriter drain)
Constructs a XPBufferedWriter object.

Parameters:
drain - A XPWriter.

XPBufferedWriter

public XPBufferedWriter(java.io.Writer writer)
Constructs a XPBufferedWriter object.

Parameters:
writer - A Writer.

XPBufferedWriter

public XPBufferedWriter(java.io.BufferedWriter bufferedWriter)
Creates a new XPBufferedWriter that wraps the BufferedWriter.

Parameters:
bufferedWriter - An instance of bufferedWriter
Method Detail

WriteLine

public void WriteLine(int b)
Writes a single character, followed by a line terminator to the stream.

Overrides:
WriteLine in class XPWriter
Parameters:
b - A character
Throws:
XPIOException

WriteLine

public void WriteLine(char[] buffer)
Writes an array of characters, followed by a line terminator to the stream.

Overrides:
WriteLine in class XPWriter
Parameters:
buffer - Array of characters
Throws:
XPIOException

WriteLine

public void WriteLine(java.lang.String buffer,
                      int offset,
                      int count)
Writes a portion of a string, followed by a line terminator to the stream.

Overrides:
WriteLine in class XPWriter
Parameters:
buffer - A string
offset - Offset from which to start reading characters
count - Number of characters to write
Throws:
XPIOException

GetUnderlyingObject

public java.io.BufferedWriter GetUnderlyingObject()
Returns the underlying platform-specific instance for framework use. References to the return type or methods other than as an Object are not translatable.

Returns:
the BufferedWriter (Java) or TextWriter (.NET) underlying the cross-platform wrapper.

WriteLine

public void WriteLine(java.lang.String line)
Writes a string, followed by a line terminator to the stream.

Overrides:
WriteLine in class XPWriter
Parameters:
line - A String.


Copyright 2002, 2003, 2004 Plumtree Software Inc. All Rights Reserved.