|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.marketcetera.util.file.CopyBytesUtils
public final class CopyBytesUtils
Utilities for copying binary data. The participating media include files, arrays, streams, or some combinations thereof.
| Method Summary | |
|---|---|
static void |
copy(byte[] data,
String name)
Copies an in-memory byte array into the given location. |
static long |
copy(InputStream in,
boolean inSkipClose,
OutputStream out,
boolean outSkipClose)
Copies a byte stream from the given source to the given sink. |
static long |
copy(InputStream in,
boolean skipClose,
String out)
Copies a byte stream from the given source to the given location. |
static byte[] |
copy(String name)
Copies a byte stream from the given location into memory, returning a byte array. |
static long |
copy(String in,
OutputStream out,
boolean skipClose)
Copies a byte stream from the given location to the given sink. |
static long |
copy(String in,
String out)
Copies a byte stream from one given location to another. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static long copy(InputStream in,
boolean inSkipClose,
OutputStream out,
boolean outSkipClose)
throws I18NException
in - The byte source, as interpreted by InputStreamWrapper.InputStreamWrapper(InputStream,boolean).inSkipClose - True if the source stream should not be
closed.out - The byte sink, as interpreted by OutputStreamWrapper.OutputStreamWrapper(OutputStream,boolean).outSkipClose - True if the sink stream should not be
closed.
I18NException - Thrown if there is a data read/write
error.
public static long copy(String in,
String out)
throws I18NException
in - The name of the byte source, as interpreted by InputStreamWrapper.InputStreamWrapper(String).out - The name of the byte sink, as interpreted by OutputStreamWrapper.OutputStreamWrapper(String).
I18NException - Thrown if there is a data read/write
error.
public static long copy(InputStream in,
boolean skipClose,
String out)
throws I18NException
in - The byte source, as interpreted by InputStreamWrapper.InputStreamWrapper(InputStream,boolean).skipClose - True if the source stream should not be
closed.out - The name of the byte sink, as interpreted by OutputStreamWrapper.OutputStreamWrapper(String).
I18NException - Thrown if there is a data read/write
error.
public static long copy(String in,
OutputStream out,
boolean skipClose)
throws I18NException
in - The name of the byte source, as interpreted by InputStreamWrapper.InputStreamWrapper(String).out - The byte sink, as interpreted by OutputStreamWrapper.OutputStreamWrapper(OutputStream,boolean).skipClose - True if the sink stream should not be closed.
I18NException - Thrown if there is a data read/write
error.
public static byte[] copy(String name)
throws I18NException
name - The name of the byte source, as interpreted by
InputStreamWrapper.InputStreamWrapper(String).
I18NException - Thrown if there is a data read/write
error.
public static void copy(byte[] data,
String name)
throws I18NException
data - The array.name - The name of the byte sink, as interpreted by OutputStreamWrapper.OutputStreamWrapper(String).
I18NException - Thrown if there is a data read/write
error.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||