|
JavaGenes, NASA Ames. Written largely by Al Globus | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgov.nasa.alsUtility.Saver
This class is intended to buffer up many timesteps or generations of data and then save them as an array using java serialization. The file name is appended with an ASCII number that should be in alphabetical order. Every save call creates an additional file in a specified directory.
Field Summary | |
protected java.util.Vector |
data
|
protected java.lang.String |
directoryName
directory to save data in |
protected int |
numberOfSaves
|
Constructor Summary | |
Saver(java.lang.String s)
|
Method Summary | |
void |
buffer(java.lang.Object object)
add object to the buffer for later saving |
void |
save()
save an array of objects that were buffered |
void |
save(java.io.Serializable object)
save an single object |
void |
setNumber(int number)
set the number used to name files |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.lang.String directoryName
protected int numberOfSaves
protected java.util.Vector data
Constructor Detail |
public Saver(java.lang.String s)
s
- directory name to save data in. Directory will be createdMethod Detail |
public void buffer(java.lang.Object object)
public void save()
public void save(java.io.Serializable object)
public void setNumber(int number)
|
JavaGenes, NASA Ames. Written largely by Al Globus | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |