|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectHitman.IOUtil
public class IOUtil
IO utility functions
| Constructor Summary | |
|---|---|
IOUtil()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
exec(java.lang.String cmd)
Execute a command (system() equivalent) |
static java.lang.String |
getExt(java.io.File file)
Split the extension from a filename. |
static java.lang.String |
getFileType(java.io.File file)
Determine the MIMEtype of a file (UNIX-specific function). |
static java.lang.String |
slurp(java.io.Reader in)
Read a String from a Reader until EOF |
static java.lang.String |
slurp(java.io.Reader r,
byte __unused)
|
static java.lang.String |
slurp(java.io.Reader in,
long len)
Read a string from a Reader. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IOUtil()
| Method Detail |
|---|
public static java.lang.String slurp(java.io.Reader in,
long len)
throws java.io.IOException
in - Reader to read fromlen - Number of bytes to read
java.io.IOException
public static java.lang.String slurp(java.io.Reader in)
throws java.io.IOException
in - Reader to read from
java.io.IOException
public static java.lang.String slurp(java.io.Reader r,
byte __unused)
throws java.io.IOException
java.io.IOException
public static java.lang.String exec(java.lang.String cmd)
throws java.io.IOException
cmd - The command to execute
java.io.IOException
public static java.lang.String getFileType(java.io.File file)
throws java.io.IOException
file - The relevant file
java.io.IOExceptionpublic static java.lang.String getExt(java.io.File file)
file - The relevant file
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||