|
SourceJammer 1.2.0.1 May 20, 2002 Copyright (c) 2001, 2002 Robert MacGrogan |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.sourcejammer.client.filesys.FileSysUtil
Client file system utilities.
Method Summary | |
static long |
fileCheckSum(byte[] file)
Returns the sum of all bytes in the byte array. |
static long |
fileCheckSum(java.io.File fl)
Returns the sum of all bytes in the file. |
static long |
fileCheckSum(java.lang.String sFullPathAndName)
Returns the sum of all bytes in the file. |
static void |
makeFileWritable(java.io.File file)
Makes a read-only file writable. |
static byte[] |
readLocalFile(java.io.File fileRead)
Returns the file at the specified location as an array of bytes. |
static byte[] |
readLocalFile(java.lang.String sFullPathAndName)
Returns the file at the specified location as an array of bytes. |
static java.lang.Object |
readObjectFromFileSys(java.io.File fileRead)
Read and return a serialized object from specified File. |
static boolean |
streamFileToFile(java.io.File flSource,
java.io.File flTarget,
boolean setToReadOnly,
boolean promptIfWritable)
|
static boolean |
writeLocalFile(java.io.File flTargetDirectory,
java.lang.String sName,
byte[] file)
Write the byte array file to the specified directory using the specified name. |
static boolean |
writeLocalFile(java.io.File flTargetDirectory,
java.lang.String sName,
byte[] file,
boolean setToReadOnly,
boolean promptIfWritable)
Write the byte array file to the specified directory using the specified name. |
static void |
writeObjectToFileSys(java.lang.Object o,
java.io.File fileWrite)
Writes the object to the specified location on the file system. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static byte[] readLocalFile(java.lang.String sFullPathAndName) throws java.io.IOException
public static byte[] readLocalFile(java.io.File fileRead) throws java.io.IOException
public static boolean writeLocalFile(java.io.File flTargetDirectory, java.lang.String sName, byte[] file) throws java.io.IOException
public static boolean streamFileToFile(java.io.File flSource, java.io.File flTarget, boolean setToReadOnly, boolean promptIfWritable) throws java.io.IOException
public static boolean writeLocalFile(java.io.File flTargetDirectory, java.lang.String sName, byte[] file, boolean setToReadOnly, boolean promptIfWritable) throws java.io.IOException
flTargetDirectory
- -- the directory to write the file to.sName
- -- the name to give the file.file
- -- the byte array that is the file's contents.setReadOnly
- -- if true, sets the file to readonly after writing it.promptIfWritable
- -- if true, prompts the user about overwriting the
file if the file exists and is NOT read-only.public static void makeFileWritable(java.io.File file) throws java.io.IOException
public static long fileCheckSum(java.lang.String sFullPathAndName) throws java.io.IOException
public static long fileCheckSum(java.io.File fl) throws java.io.IOException
public static long fileCheckSum(byte[] file)
public static java.lang.Object readObjectFromFileSys(java.io.File fileRead) throws java.io.IOException
public static void writeObjectToFileSys(java.lang.Object o, java.io.File fileWrite) throws java.io.IOException
|
SourceJammer 1.2.0.1 May 20, 2002 Copyright (c) 2001, 2002 Robert MacGrogan |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |