org.apache.commons.io.output
Class ProxyWriter
FilterWriter
org.apache.commons.io.output.ProxyWriter
public class ProxyWriter
extends FilterWriter
A Proxy stream which acts as expected, that is it passes the method
calls on to the proxied stream and doesn't change which methods are
being called. It is an alternative base class to FilterWriter
to increase reusability, because FilterWriter changes the
methods being called, such as write(char[]) to write(char[], int, int)
and write(String) to write(String, int, int).
$Id: ProxyWriter.java 610010 2008-01-08 14:50:59Z niallp $ProxyWriter(Writer proxy) - Constructs a new ProxyWriter.
|
void | close() - Invokes the delegate's
close() method.
|
void | flush() - Invokes the delegate's
flush() method.
|
void | write(String str) - Invokes the delegate's
write(String) method.
|
void | write(String str, int st, int end) - Invokes the delegate's
write(String) method.
|
void | write(char[] chr) - Invokes the delegate's
write(char[]) method.
|
void | write(char[] chr, int st, int end) - Invokes the delegate's
write(char[], int, int) method.
|
void | write(int idx) - Invokes the delegate's
write(int) method.
|
ProxyWriter
public ProxyWriter(Writer proxy)
Constructs a new ProxyWriter.
proxy
- the Writer to delegate to
close
public void close()
throws IOException
Invokes the delegate's close()
method.
flush
public void flush()
throws IOException
Invokes the delegate's flush()
method.
write
public void write(String str)
throws IOException
Invokes the delegate's write(String)
method.
str
- the string to write
write
public void write(String str,
int st,
int end)
throws IOException
Invokes the delegate's write(String)
method.
str
- the string to writest
- The start offsetend
- The number of characters to write
write
public void write(char[] chr)
throws IOException
Invokes the delegate's write(char[])
method.
chr
- the characters to write
write
public void write(char[] chr,
int st,
int end)
throws IOException
Invokes the delegate's write(char[], int, int)
method.
chr
- the characters to writest
- The start offsetend
- The number of characters to write
write
public void write(int idx)
throws IOException
Invokes the delegate's write(int)
method.
idx
- the character to write
Copyright (c) 2002-2009 Apache Software Foundation