com.basho.riak.client.response
Class StreamedKeysCollection
java.lang.Object
com.basho.riak.client.util.CollectionWrapper<String>
com.basho.riak.client.response.StreamedKeysCollection
- All Implemented Interfaces:
- Iterable<String>, Collection<String>
Deprecated. with the addition of a protocol buffers client in 0.14 all the
existing REST client code should be in client.http.* this class
has therefore been moved. Please use
com.basho.riak.client.http.response.StreamedKeysCollection
instead.
WARNING: This class will be REMOVED in the next version.
@Deprecated
public class StreamedKeysCollection
- extends CollectionWrapper<String>
Presents the stream of keys from a Riak bucket response with query parameter
keys=stream as a collection. Keys are read from the stream as needed. Note,
this class is NOT thread-safe!
- See Also:
StreamedKeysCollection
Method Summary |
protected boolean |
cacheNext()
Deprecated. Tries to read and cache another set of keys from the input stream. |
protected void |
closeBackend()
Deprecated. Close the backend so no more objects can be read from it (getNext()
should only return null afterwards). |
Methods inherited from class com.basho.riak.client.util.CollectionWrapper |
add, addAll, cache, clear, contains, containsAll, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StreamedKeysCollection
public StreamedKeysCollection(JSONTokener tokens)
- Deprecated.
cacheNext
protected boolean cacheNext()
- Deprecated.
- Tries to read and cache another set of keys from the input stream. This
function is actually just a hacked-up implementation that finds the next
available array in the stream and sucks elements out of it.
- Specified by:
cacheNext
in class CollectionWrapper<String>
- Returns:
- true if an object was added to the cache; false otherwise.
closeBackend
protected void closeBackend()
- Deprecated.
- Description copied from class:
CollectionWrapper
- Close the backend so no more objects can be read from it (getNext()
should only return null afterwards). Called by clear().
- Specified by:
closeBackend
in class CollectionWrapper<String>
Copyright © 2012. All Rights Reserved.