|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectariba.util.core.TableUtil
public final class TableUtil
Table file Utilities. These are helper functions for dealing with table files.
| Method Summary | |
|---|---|
static Map |
loadMap(File file)
Load a serialized Map from the given file. |
static Map |
loadMap(File file,
boolean displayError)
Load a serialized Map from the given url. |
static Map |
loadMap(String s,
boolean displayError)
Load a serialized Map from the given String. |
static Map |
loadMap(URL url)
Load a serialized Map from the given url. |
static Map |
loadMap(URL url,
boolean displayError)
Load a serialized Map from the given url. |
static Object |
loadObject(File file)
Load an object from a file using loadObject(Reader) |
static Object |
loadObject(Reader reader)
Load an object from a stream. |
static Object |
loadObject(URL url)
Load an object from a URL using loadObject(Reader) |
static void |
main(String[] args)
|
static boolean |
safeWriteObject(File file,
Object object)
Writes an object to a file in safe way. |
static boolean |
writeObject(File file,
Object object)
Write an object to a file. |
static boolean |
writeObject(OutputStream outputStream,
Object object)
Write an object to an OutputStream. |
static boolean |
writeObject(PrintWriter printWriter,
Object object)
Write an object to a printWriter. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static Map loadMap(File file)
file - the File to load the serialized Map from
public static Map loadMap(File file,
boolean displayError)
file - the File to load the serialized Map fromdisplayError - if true and there are errors
deserializing the Map, an error will be printed.
public static Map loadMap(URL url)
url - the URL to load the serialized Map from
public static Map loadMap(URL url,
boolean displayError)
url - the URL to load the serialized Map fromdisplayError - if true and there are errors
deserializing the Map, an error will be printed.
public static Map loadMap(String s,
boolean displayError)
s - the String to load the serialized Map fromdisplayError - if true and there are errors
deserializing the Map, an error will be printed.
public static Object loadObject(URL url)
url - the URL to load the object from
loadObject(Reader)public static Object loadObject(File file)
file - the path for the file to load the object from
loadObject(Reader)
public static Object loadObject(Reader reader)
throws IOException
reader - the source for the Object's data
IOException - if there was an error deserializing the
object.
public static boolean safeWriteObject(File file,
Object object)
writeObject
but it actually uses the FileReplacer to be more robust.
file - the path for a file to write the object toobject - the Object to serialize into the file
public static boolean writeObject(File file,
Object object)
file - the path for a file to write the object toobject - the Object to serialize into the file
public static boolean writeObject(OutputStream outputStream,
Object object)
outputStream - the OutputStream to write the object toobject - the Object to serialize into the file
public static boolean writeObject(PrintWriter printWriter,
Object object)
printWriter - the PrintWriter to write the object toobject - the Object to serialize into the file
public static void main(String[] args)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||