|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.axiom.attachments.utils.IOUtils
public class IOUtils
Utility class containing IO helper methods
| Method Summary | |
|---|---|
static byte[] |
getStreamAsByteArray(java.io.InputStream stream)
Returns the contents of the input stream as byte array. |
static byte[] |
getStreamAsByteArray(java.io.InputStream stream,
int length)
Returns the contents of the input stream as byte array. |
static int |
readFully(java.io.InputStream in,
byte[] b)
Reads into a byte array. |
static int |
readFully(java.io.InputStream in,
byte[] b,
int off,
int len)
Same as the normal in.read(b, off, len), but tries to ensure that the entire len number of bytes is read. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static int readFully(java.io.InputStream in,
byte[] b)
throws java.io.IOException
java.io.IOExceptionreadFully(java.io.InputStream, byte[], int, int)
public static int readFully(java.io.InputStream in,
byte[] b,
int off,
int len)
throws java.io.IOException
java.io.IOException
public static byte[] getStreamAsByteArray(java.io.InputStream stream)
throws java.io.IOException
stream - the InputStream
java.io.IOException
public static byte[] getStreamAsByteArray(java.io.InputStream stream,
int length)
throws java.io.IOException
stream - the InputStreamlength - the number of bytes to copy, if length < 0, the number is unlimited
java.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||