|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface SinglevaluedIndex
Representation index where exactly one value is associated with each key.
| Method Summary | |
|---|---|
java.lang.Object |
get(java.lang.Object key)
Returns the value to which this index maps the specified key. |
java.lang.Object |
getIfExists(java.lang.Object key)
Returns the value to which this index maps the specified key or null if there is no value for this key. |
java.lang.Object |
getObject(java.lang.Object key,
SinglevaluedIndex repos)
Like get, but if the index contains keys, this returns the object corresponding to the key |
java.lang.Object |
getObjectIfExists(java.lang.Object key,
SinglevaluedIndex repos)
Like getIfExists, but if the index contains keys, this returns the object corresponding to the key |
boolean |
put(java.lang.Object key,
java.lang.Object value)
Associates the specified value with the specified key in this index. |
java.util.Collection |
queryByKeyPrefix(java.lang.Object prefix,
SinglevaluedIndex repos)
Returns a collection view of Map.Entry key-value pairs in the index,
where key matches the queried prefix. |
void |
replace(java.lang.Object key,
java.lang.Object value)
Replaces the original value associated with the specified key in this index with new value. |
java.util.Collection |
values()
Returns a collection view of the values contained in this index. |
| Methods inherited from interface org.netbeans.mdr.persistence.Index |
|---|
add, getKeyType, getName, getValueType, keySet, remove |
| Method Detail |
|---|
boolean put(java.lang.Object key,
java.lang.Object value)
throws StorageException
key - value -
StorageException
void replace(java.lang.Object key,
java.lang.Object value)
throws StorageException,
StorageBadRequestException
key - value -
StorageException
StorageBadRequestException
java.lang.Object get(java.lang.Object key)
throws StorageException,
StorageBadRequestException
key -
StorageException
StorageBadRequestException
java.lang.Object getObject(java.lang.Object key,
SinglevaluedIndex repos)
throws StorageException
key -
StorageException
java.lang.Object getIfExists(java.lang.Object key)
throws StorageException
key -
StorageException
java.lang.Object getObjectIfExists(java.lang.Object key,
SinglevaluedIndex repos)
throws StorageException
key -
StorageException
java.util.Collection values()
throws StorageException
StorageException
java.util.Collection queryByKeyPrefix(java.lang.Object prefix,
SinglevaluedIndex repos)
throws StorageException
Map.Entry key-value pairs in the index,
where key matches the queried prefix. Values are objects (as returned by getObject
method).
prefix - queried prefixrepos - primary index
StorageException
java.lang.UnsupportedOperationException - thrown if the index does not support quries on
prefixes (due to unsuitable key entry type, etc.)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||