|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--qdbm.Util
Class of utility methods.
Method Summary | |
static int |
chdir(java.lang.String path)
Change current working directory using the native function `chdir' defined in POSIX. |
static java.lang.Object |
deserialize(byte[] serial)
Redintegrate a serialized object. |
static long |
deserializeLong(byte[] serial)
Redintegrate a serialized long integer. |
static java.lang.String |
getcwd()
Get current working directory using the native function `getcwd' defined in POSIX. |
static int |
getpid()
Get process identification using the native function `getpid' defined in POSIX. |
static java.lang.String |
numstr(int num,
int cols,
char padding)
Get a formatted decimal string made from a number. |
static byte[] |
serialize(java.lang.Object obj)
Serialize an object. |
static byte[] |
serializeLong(long num)
Serialize a long integer. |
static int |
system(java.lang.String cmd)
Execute a shell command using the native function `system' defined in POSIX and ANSI C. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static int chdir(java.lang.String path)
path
- the path of a directory.
public static java.lang.Object deserialize(byte[] serial)
serial
- a byte array of the serialized object.
public static long deserializeLong(byte[] serial) throws java.lang.IllegalArgumentException
serial
- a byte array of a serialized long integer.
java.lang.IllegalArgumentException
- thrown if the size of the array is invalid.public static java.lang.String getcwd()
public static int getpid()
public static java.lang.String numstr(int num, int cols, char padding)
num
- a number.cols
- the number of columns. The result string may be longer than it.padding
- a padding character to fulfil columns with.public static byte[] serialize(java.lang.Object obj)
obj
- a serializable object.
public static byte[] serializeLong(long num)
num
- a long integer.
public static int system(java.lang.String cmd)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |