|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jboss.dna.common.util.IoUtil
public class IoUtil
| Method Summary | |
|---|---|
static java.lang.String |
read(java.io.InputStream stream)
Read and return the entire contents of the supplied InputStream. |
static java.lang.String |
read(java.io.Reader reader)
Read and return the entire contents of the supplied Reader. |
static byte[] |
readBytes(java.io.InputStream stream)
Read and return the entire contents of the supplied stream. |
static void |
write(java.io.InputStream input,
java.io.OutputStream stream)
Write the entire contents of the supplied string to the given stream. |
static void |
write(java.io.Reader input,
java.io.Writer writer)
Write the entire contents of the supplied string to the given writer. |
static void |
write(java.lang.String content,
java.io.OutputStream stream)
Write the entire contents of the supplied string to the given stream. |
static void |
write(java.lang.String content,
java.io.Writer writer)
Write the entire contents of the supplied string to the given writer. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static byte[] readBytes(java.io.InputStream stream)
throws java.io.IOException
stream. This method always closes the stream when
finished reading.
stream - the stream to the contents; may be null
java.io.IOException - if there is an error reading the content
public static java.lang.String read(java.io.Reader reader)
throws java.io.IOException
Reader. This method always closes the reader when finished
reading.
reader - the reader of the contents; may be null
java.io.IOException - if there is an error reading the content
public static java.lang.String read(java.io.InputStream stream)
throws java.io.IOException
InputStream. This method always closes the stream when
finished reading.
stream - the streamed contents; may be null
java.io.IOException - if there is an error reading the content
public static void write(java.lang.String content,
java.io.OutputStream stream)
throws java.io.IOException
content - the content to write to the stream; may be nullstream - the stream to which the content is to be written
java.io.IOException
java.lang.IllegalArgumentException - if the stream is null
public static void write(java.lang.String content,
java.io.Writer writer)
throws java.io.IOException
content - the content to write to the writer; may be nullwriter - the writer to which the content is to be written
java.io.IOException
java.lang.IllegalArgumentException - if the writer is null
public static void write(java.io.InputStream input,
java.io.OutputStream stream)
throws java.io.IOException
input - the content to write to the stream; may be nullstream - the stream to which the content is to be written
java.io.IOException
java.lang.IllegalArgumentException - if the stream is null
public static void write(java.io.Reader input,
java.io.Writer writer)
throws java.io.IOException
input - the content to write to the writer; may be nullwriter - the writer to which the content is to be written
java.io.IOException
java.lang.IllegalArgumentException - if the writer is null
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||