FileDocCategorySizeDatePackage
WriterOutputBuffer.javaAPI DocJava SE 6 API2344Tue Jun 10 00:22:34 BST 2008com.sun.org.apache.xalan.internal.xsltc.runtime.output

WriterOutputBuffer

public class WriterOutputBuffer extends Object implements OutputBuffer
author
Santiago Pericas-Geertsen

Fields Summary
private static final int
KB
private static int
BUFFER_SIZE
private Writer
_writer
Constructors Summary
public WriterOutputBuffer(Writer writer)
Initializes a WriterOutputBuffer by creating an instance of a BufferedWriter. The size of the buffer in this writer may have a significant impact on throughput. Solaris prefers a larger buffer, while Linux works better with a smaller one.

	_writer = new BufferedWriter(writer, BUFFER_SIZE);
    
Methods Summary
public com.sun.org.apache.xalan.internal.xsltc.runtime.output.OutputBufferappend(java.lang.String s)

	try {
	    _writer.write(s);
	}
	catch (IOException e) {
	    throw new RuntimeException(e.toString());
	}
	return this;
    
public com.sun.org.apache.xalan.internal.xsltc.runtime.output.OutputBufferappend(char[] s, int from, int to)

	try {
	    _writer.write(s, from, to);
	}
	catch (IOException e) {
	    throw new RuntimeException(e.toString());
	}
	return this;
    
public com.sun.org.apache.xalan.internal.xsltc.runtime.output.OutputBufferappend(char ch)

	try {
	    _writer.write(ch);
	}
	catch (IOException e) {
	    throw new RuntimeException(e.toString());
	}
	return this;
    
public java.lang.Stringclose()

	try {
	    _writer.flush();
	}
	catch (IOException e) {
	    throw new RuntimeException(e.toString());
	}
	return "";