|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.sap.ip.me.api.services.MultiObjectFileStorage
This class stores serializable objects in the file system with each object tree being stored in a seperate file.
| Method Summary | |
java.util.Enumeration |
allObjects()
This method returns all objects that are accessible with this instance. |
java.util.Enumeration |
bufferedObjects()
This method returns all cached objects. |
void |
commit()
This method executes all changes prepared by writeOnCommit / deleteOnCommit on the file-system. |
static MultiObjectFileStorage |
createInstance(java.lang.String subDirectory)
This method returns a MultiObjectFileStorage instance for a
given subdirectory. |
void |
delete(java.lang.String key)
This method immediately deletes an object from the file-system |
void |
deleteOnCommit(java.lang.String key)
This method prepares an object to be deleted to the file-system. |
java.lang.Object |
read(java.lang.String key)
This method reads an object from the storage. |
java.lang.Object |
read(java.lang.String key,
boolean bypassCache)
This method reads an object from the storage with explictly ignoring the cache (if the bypassCache parameter is set to false). |
void |
rollback()
This mehtod reverses all changes prepared by writeOnCommit / deleteOnCommit since the last commit Technically, this is archieved by re-reading the cache. |
void |
write(java.lang.String key,
java.lang.Object value)
This method immedeately writes any object to the file-system. |
void |
writeOnCommit(java.lang.String key,
java.lang.Object value)
This method prepares an object to be written to 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 MultiObjectFileStorage createInstance(java.lang.String subDirectory)
MultiObjectFileStorage instance for a
given subdirectory.
subDirectory - The subdirectory for the MultiObjectFileStorage
.
MultiObjectFileStorage instance for a
given subdirectory. null iff there are any failures while
creating a MultiObjectFileStorage instance.public java.lang.Object read(java.lang.String key)
key - Unique key which the object is associated to
public java.lang.Object read(java.lang.String key,
boolean bypassCache)
key - Unique key the object is associated tobypassCache - If true then read directly from file and
update the cache otherwise the object will be get from cache.
public void write(java.lang.String key,
java.lang.Object value)
key - Unique key the object is associated to.value - Object to be stored.public void delete(java.lang.String key)
key - The key of the object that has to be deleted.
public void writeOnCommit(java.lang.String key,
java.lang.Object value)
key - The unique key that represents the object.value - The object istself.public void deleteOnCommit(java.lang.String key)
key - The unique key of the object that has to be deleted.public void commit()
public java.util.Enumeration bufferedObjects()
public java.util.Enumeration allObjects()
public void rollback()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||