public static interface LockBox.Entry
LockBox
.
Entries are created using LockBox.register(Object)
.
The object can be retrieved using getValue()
if you have
the entry, or LockBox.get(String)
if you only have the
string key.
Holding onto an Entry will prevent the entry, and the associated value from being garbage collected. Holding onto the moniker will not prevent garbage collection.
Modifier and Type | Method and Description |
---|---|
String |
getMoniker()
String key by which to identify this object.
|
Object |
getValue()
Returns the value in this lock box entry.
|
boolean |
isRegistered()
Returns whether the entry is still valid.
|
Object getValue()
String getMoniker()
Given this moniker, you retrieve the Entry using
LockBox.get(String)
. The retrieved Entry will will have the
same moniker, and will be able to access the same value.
boolean isRegistered()
LockBox.deregister(mondrian.util.LockBox.Entry)
has been
called on this Entry or any entry with the same moniker.Copyright © 2018 Hitachi Vantara. All rights reserved.