| 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--net.walend.lyophil.memory.MemStorage
An in-memory storage point.
| Field Summary | |
protected  Caster | 
caster
 | 
protected  MultiValueIndex | 
classIndex
 | 
protected  MemSet | 
memSet
 | 
static java.lang.String | 
MEMSTORAGE
 | 
protected  SingleValueIndex | 
typableKeyIndex
 | 
| Constructor Summary | |
MemStorage()
 | 
|
| Method Summary | |
 void | 
clear()
 | 
 boolean | 
containsTypableKey(java.lang.String key)
Returns true if the typable key is in use already.  | 
 int | 
count()
 | 
 int | 
countByClass(java.lang.Class interf)
Count the number of freezables that implement this interf.  | 
 SetOfFreezables | 
findByClass(java.lang.Class interf)
Returns the set of Freezables that can be cast to interf.  | 
 Freezable | 
findByIdentifier(java.io.Serializable identifier)
Freeze and findByIdentifier methods in MemStorage always return the same instance of the object.  | 
 HasTypableKey | 
findByTypableKey(java.lang.String key)
Returns the Freezable that has the typable key  | 
 java.io.Serializable | 
findIDForTypableKey(java.lang.String key)
 | 
 void | 
freeze(Freezable victem)
Put the victem in all the Maps.  | 
 SetOfFreezables | 
getAll()
 | 
protected  void | 
init()
This method should be called by the MemStorage constructor only.  | 
 boolean | 
isAvailable(java.io.Serializable identifier)
 | 
 void | 
throwOut(java.io.Serializable identifier)
Remove this victem from all the Maps  | 
| Methods inherited from class java.lang.Object | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
public static final java.lang.String MEMSTORAGE
protected MemSet memSet
protected MultiValueIndex classIndex
protected SingleValueIndex typableKeyIndex
protected Caster caster
| Constructor Detail | 
public MemStorage()
| Method Detail | 
protected void init()
public void freeze(Freezable victem)
Freeze and findByIdentifier methods in MemStorage always return the same instance of the object. This behavior is appropirate for client object caches, but not for safe transactions.
public Freezable findByIdentifier(java.io.Serializable identifier)
                           throws NotInFreezerException
public void throwOut(java.io.Serializable identifier)
              throws NotInFreezerException
public boolean isAvailable(java.io.Serializable identifier)
public SetOfFreezables getAll()
public void clear()
public int count()
public int countByClass(java.lang.Class interf)
public SetOfFreezables findByClass(java.lang.Class interf)
PersistenceFailureException
public HasTypableKey findByTypableKey(java.lang.String key)
                               throws NotInFreezerException
PersistenceFailureExceptionNotInFreezerException
public java.io.Serializable findIDForTypableKey(java.lang.String key)
                                         throws NotInFreezerException
public boolean containsTypableKey(java.lang.String key)
PersistenceFailureException
  | 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||