public class BlockingStorage extends Object
Storage.| Constructor and Description |
|---|
BlockingStorage(Storage storage)
Wrap a
Storage in order get a blocking version of it. |
| Modifier and Type | Method and Description |
|---|---|
void |
delete(Key key)
Removes value from storage.
|
boolean |
exists(Key key)
This file exists?
|
Collection<Key> |
list(Key prefix)
Return the list of keys that start with this prefix, for
example "foo/bar/".
|
void |
move(Key source,
Key destination)
Moves value from one location to another.
|
void |
save(Key key,
byte[] content)
Save the content.
|
long |
size(Key key)
Get value size.
|
byte[] |
value(Key key)
Obtain value for the specified key.
|
public boolean exists(Key key)
key - The key (file name)public Collection<Key> list(Key prefix)
prefix - The prefix.public void save(Key key, byte[] content)
key - The keycontent - The contentpublic void move(Key source, Key destination)
source - Source key.destination - Destination key.public long size(Key key)
key - The key of value.public byte[] value(Key key)
key - The keypublic void delete(Key key)
key - Key for value to be deleted.Copyright © 2019–2020 jcabi.com. All rights reserved.