|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.lonniepryor.blues.Local
Provides a service similiar to the ThreadLocal class, except values of blues Locals can only exist between the creation of a Session and the subsequent calling of it's dispose() method. Values of these Locals will therefore be safely disposed of without relying on garbage collection.
Constructor Summary | |
Local()
Creates a new Local object. |
Method Summary | |
protected java.lang.Object |
createValue()
Creates the inital value of this Local, returns null by default. |
protected void |
disposeValue(java.lang.Object value)
Disposed the value of this local when the Session is disposed, does nothing by default. |
boolean |
equals(java.lang.Object obj)
|
java.lang.Object |
get()
Returns the value of this Local in the currently bound Session. |
int |
hashCode()
|
void |
set(java.lang.Object value)
Sets the value of this Local in the currently bound Session. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Local()
Method Detail |
public final java.lang.Object get()
public final void set(java.lang.Object value)
value
- The new value of this Local in the currently bound Session.public final boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public final int hashCode()
hashCode
in class java.lang.Object
protected java.lang.Object createValue()
protected void disposeValue(java.lang.Object value)
value
- The local value to dispose.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |