public interface TransientStore
Allows to store entries in 2 sub parts: a list of blobs stored on a file system along with a map of parameters.
Modifier and Type | Method and Description |
---|---|
boolean |
exists(String key)
Returns
true if an entry exists with the given key . |
List<Blob> |
getBlobs(String key)
Gets the blobs associated with the entry with the given
key . |
Serializable |
getParameter(String key,
String parameter)
Gets the value of
parameter in the entry with the given key . |
Map<String,Serializable> |
getParameters(String key)
Gets values of the parameters in the entry with the given
key . |
long |
getSize(String key)
Returns the size of the blobs associated with the entry with the given
key or -1 if entry does
not exist. |
boolean |
isCompleted(String key)
Returns
true if the entry with the given key is ready. |
void |
putBlobs(String key,
List<Blob> blobs)
Associates the given
blobs with the entry with the given key . |
void |
putParameter(String key,
String parameter,
Serializable value)
Sets
parameter to value in the entry with the given key . |
void |
putParameters(String key,
Map<String,Serializable> parameters)
Puts
parameters in the entry with the given key . |
void |
release(String key)
Informs the store that the entry with the given
key can be released if TTL or GC parameters require to do
some cleanup. |
void |
remove(String key)
Removes entry with the given
key . |
void |
setCompleted(String key,
boolean completed)
Marks the entry with the given
key as ready. |
void putParameter(String key, String parameter, Serializable value)
parameter
to value
in the entry with the given key
.
If entry does not exist a new entry is created. If parameter
already exists in the entry it is
overwritten.
Serializable getParameter(String key, String parameter)
parameter
in the entry with the given key
.
Returns null
if entry or parameter does not exist.
void putParameters(String key, Map<String,Serializable> parameters)
parameters
in the entry with the given key
. Overwrites any existing parameter in the entry.
If entry does not exist a new entry is created.
Map<String,Serializable> getParameters(String key)
key
.
Returns null
if entry does not exist.
void putBlobs(String key, List<Blob> blobs)
blobs
with the entry with the given key
.
If entry does not exist a new entry is created.
List<Blob> getBlobs(String key)
key
.
Returns null
if entry does not exist.
long getSize(String key)
key
or -1
if entry does
not exist.boolean isCompleted(String key)
true
if the entry with the given key
is ready.void setCompleted(String key, boolean completed)
key
as ready.
If entry does not exist a new entry is created.
void remove(String key)
key
.
Has no effect if entry does not exist.
Copyright © 2018 Nuxeo. All rights reserved.