net.citrusleaf
Class CitrusleafClient

java.lang.Object
  extended by com.aerospike.client.AerospikeClient
      extended by net.citrusleaf.CitrusleafClient
All Implemented Interfaces:
Log.Callback

public class CitrusleafClient
extends AerospikeClient
implements Log.Callback

Legacy compatibility Layer. This class should only be used for legacy code. Please use com.aerospike.client.AerospikeClient for new code.

Instantiate a CitrusleafClient object to access a Citrusleaf database cluster and perform database operations.

Your application uses this class API to perform database operations such as writing and reading records, and scanning sets of records. Write operations include specialized functionality such as append/prepend and arithmetic addition.

Records are stored and identified using a specified namespace, an optional set name, and a key which must be unique within a set.

Each record may have multiple bins, unless the Citrusleaf server nodes are configured as "single-bin". In "multi-bin" mode, partial records may be written or read by specifying the relevant subset of bins.


Nested Class Summary
static class CitrusleafClient.ClBin
          Container object for record bin name/value pair.
static class CitrusleafClient.ClLogLevel
          Log escalation level.
static class CitrusleafClient.ClOptions
          Container object for transaction policy attributes used in all database operation calls.
static class CitrusleafClient.ClResult
          Container object for database operation results.
static class CitrusleafClient.ClResultCode
          Database operation result codes.
static class CitrusleafClient.ClScanningOptions
          Container object for optional parameters used in scan operations.
static class CitrusleafClient.ClScanningPriority
          Priority of scan operations on database server.
static class CitrusleafClient.ClWriteOptions
          Container object for policy attributes used in write operations.
static interface CitrusleafClient.LogCallback
          An object implementing this interface may be passed in setLogging(), so the caller can channel Citrusleaf client logs as desired.
static interface CitrusleafClient.ScanCallback
          An object implementing this interface is passed in scan...() calls, so the caller can be notified with scan results.
 
Constructor Summary
CitrusleafClient()
          Constructor, creates CitrusleafClient object and initializes logging framework.
CitrusleafClient(java.lang.String hostname, int port)
          Constructor, combines default constructor CitrusleafClient() and addHost().
 
Method Summary
 CitrusleafClient.ClResultCode add(java.lang.Object key, java.lang.Object value)
          For integer values, and server nodes configured as "single-bin" only - add value to existing record value for specified key, using default namespace, no set name, and default options.
 CitrusleafClient.ClResultCode add(java.lang.Object key, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values, and server nodes configured as "single-bin" only - add value to existing record value for specified key, using default namespace and no set name.
 CitrusleafClient.ClResultCode add(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<CitrusleafClient.ClBin> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for each bin for specified key.
 CitrusleafClient.ClResultCode add(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Map<java.lang.String,java.lang.Object> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for each bin for specified key.
 CitrusleafClient.ClResultCode add(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.lang.String binName, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for specified key.
 CitrusleafClient.ClResult addAndGet(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<CitrusleafClient.ClBin> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for each bin for specified key, and return the results.
 CitrusleafClient.ClResult addAndGet(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Map<java.lang.String,java.lang.Object> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for each bin for specified key, and return the results.
 CitrusleafClient.ClResultCode addDigest(java.lang.String namespace, byte[] digest, CitrusleafClient.ClBin bin, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for specified key digest.
 CitrusleafClient.ClResultCode addDigest(java.lang.String namespace, byte[] digest, java.util.Collection<CitrusleafClient.ClBin> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for each bin for specified key digest.
 CitrusleafClient.ClResultCode addDigest(java.lang.String namespace, byte[] digest, java.util.Map<java.lang.String,java.lang.Object> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for each bin for specified key digest.
 CitrusleafClient.ClResultCode addDigest(java.lang.String namespace, byte[] digest, java.lang.String binName, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For integer values only - add value to existing bin value for specified key digest.
 CitrusleafClient.ClResultCode addHost(java.lang.String hostname, int port)
          Add a server database host to the client's cluster map.
 CitrusleafClient.ClResultCode append(java.lang.Object key, java.lang.Object value)
          For server nodes configured as "single-bin" only - append value to existing record value for specified key, using default namespace, no set name, and default options.
 CitrusleafClient.ClResultCode append(java.lang.Object key, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For server nodes configured as "single-bin" only - append value to existing record value for specified key, using default namespace and no set name.
 CitrusleafClient.ClResultCode append(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<CitrusleafClient.ClBin> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Append value to existing bin value for each bin for specified key.
 CitrusleafClient.ClResultCode append(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Map<java.lang.String,java.lang.Object> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Append value to existing bin value for each bin for specified key.
 CitrusleafClient.ClResultCode append(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.lang.String binName, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Append value to existing bin value for specified key.
 CitrusleafClient.ClResult[] batchExists(java.lang.String namespace, java.lang.String set, java.util.Collection<java.lang.Object> keys, CitrusleafClient.ClOptions opts)
          Batch multiple exists() requests into a single call.
 CitrusleafClient.ClResult[] batchGet(java.lang.String namespace, java.lang.String set, java.util.Collection<java.lang.Object> keys, java.util.Collection<java.lang.String> binNames, CitrusleafClient.ClOptions opts)
          Batch multiple get() requests into a single call.
 CitrusleafClient.ClResult[] batchGet(java.lang.String namespace, java.lang.String set, java.util.Collection<java.lang.Object> keys, java.lang.String binName, CitrusleafClient.ClOptions opts)
          Batch multiple get() requests into a single call.
 CitrusleafClient.ClResult[] batchGetAll(java.lang.String namespace, java.lang.String set, java.util.Collection<java.lang.Object> keys, CitrusleafClient.ClOptions opts)
          Batch multiple getAll() requests into a single call.
static void ClLog(CitrusleafClient.ClLogLevel logLevel, java.lang.String msg)
           
static byte[] computeDigest(java.lang.String set, java.lang.Object key)
          Generate digest from key and set name.
 boolean connect()
          Deprecated. 
 CitrusleafClient.ClResultCode delete(java.lang.Object key, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Delete record for specified key, using default namespace and no set name.
 CitrusleafClient.ClResultCode delete(java.lang.String namespace, java.lang.String set, java.lang.Object key, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Delete record for specified key.
 CitrusleafClient.ClResultCode deleteDigest(java.lang.String namespace, byte[] digest, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Delete record for specified key digest.
 CitrusleafClient.ClResultCode exists(java.lang.Object key)
          Check if specified key exists, using default namespace, no set name, and default options.
 CitrusleafClient.ClResultCode exists(java.lang.String namespace, java.lang.String set, java.lang.Object key, CitrusleafClient.ClOptions opts)
          Check if specified key exists.
 java.lang.Object get(java.lang.Object key)
          For server nodes configured as "single-bin" only - get record value for specified key, using default namespace, no set name, and default options.
 CitrusleafClient.ClResult get(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<java.lang.String> binNames, CitrusleafClient.ClOptions opts)
          Get bin name/value pairs for specified key and list of bin names.
 CitrusleafClient.ClResult get(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.lang.String[] binNames, CitrusleafClient.ClOptions opts)
          Get bin name/value pairs for specified key and list of bin names.
 CitrusleafClient.ClResult get(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.lang.String binName, CitrusleafClient.ClOptions opts)
          Get bin value for specified key and bin name.
 CitrusleafClient.ClResult getAll(java.lang.String namespace, java.lang.String set, java.lang.Object key, CitrusleafClient.ClOptions opts)
          Get all bin name/value pairs for specified key.
 CitrusleafClient.ClResult getAllDigest(java.lang.String namespace, byte[] digest, CitrusleafClient.ClOptions opts)
          Get all bin name/value pairs for specified key digest.
 CitrusleafClient.ClResult getDigest(java.lang.String namespace, byte[] digest, java.util.Collection<java.lang.String> binNames, CitrusleafClient.ClOptions opts)
          Get bin name/value pairs for specified key digest and list of bin names.
 CitrusleafClient.ClResult getDigest(java.lang.String namespace, byte[] digest, java.lang.String binName, CitrusleafClient.ClOptions opts)
          Get bin value for specified key digest and bin name.
 java.util.List<java.lang.String> getNodeNameList()
          Return a list of server nodes in the cluster.
 CitrusleafClient.ClResult getWithTouch(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<java.lang.String> binNames, int expiration, CitrusleafClient.ClOptions opts)
          Get bin name/value pairs for specified key and list of bin names, and if the record exists, reset record time to expiration.
 void log(Log.Level level, java.lang.String message)
          Implementation of com.aerospike.client.Log.Callback
 CitrusleafClient.ClResult operate(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<java.lang.String> readBinNames, java.util.Collection<CitrusleafClient.ClBin> writeBins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Combine get() and set() operations for a specified record.
 CitrusleafClient.ClResultCode prepend(java.lang.Object key, java.lang.Object value)
          For server nodes configured as "single-bin" only - prepend value to existing record value for specified key, using default namespace, no set name, and default options.
 CitrusleafClient.ClResultCode prepend(java.lang.Object key, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For server nodes configured as "single-bin" only - prepend value to existing record value for specified key, using default namespace and no set name.
 CitrusleafClient.ClResultCode prepend(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<CitrusleafClient.ClBin> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Prepend value to existing bin value for each bin for specified key.
 CitrusleafClient.ClResultCode prepend(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Map<java.lang.String,java.lang.Object> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Prepend value to existing bin value for each bin for specified key.
 CitrusleafClient.ClResultCode prepend(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.lang.String binName, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Prepend value to existing bin value for specified key.
 CitrusleafClient.ClResult scan(java.lang.String namespace, CitrusleafClient.ClOptions opts, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData)
          Deprecated. 
 CitrusleafClient.ClResult scan(java.lang.String namespace, CitrusleafClient.ClOptions opts, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData, boolean noBinData)
          Deprecated. 
 CitrusleafClient.ClResult scan(java.lang.String namespace, java.lang.String set, CitrusleafClient.ClOptions opts, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData)
          Deprecated. 
 CitrusleafClient.ClResult scan(java.lang.String namespace, java.lang.String set, CitrusleafClient.ClOptions opts, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData, boolean noBinData)
          Deprecated. 
 CitrusleafClient.ClResultCode scan(java.lang.String namespace, java.lang.String set, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData)
          Scan the database nodes in parallel, using specified namespace and set filters, and default options, returning a single result code.
 java.util.Map<java.lang.String,CitrusleafClient.ClResultCode> scanAllNodes(java.lang.String namespace, java.lang.String set, boolean noBinData, int scanPercent, CitrusleafClient.ClOptions opts, CitrusleafClient.ClScanningOptions scanOpts, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData)
          Scan the database nodes in parallel, using specified namespace and set filters, retrieving records or digests only, as specified.
 java.util.Map<java.lang.String,CitrusleafClient.ClResultCode> scanAllNodes(java.lang.String namespace, java.lang.String set, CitrusleafClient.ClOptions opts, CitrusleafClient.ClScanningOptions scanOpts, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData)
          Scan the database nodes in parallel, using specified namespace and set filters.
 java.util.Map<java.lang.String,CitrusleafClient.ClResultCode> scanAllNodes(java.lang.String namespace, java.lang.String set, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData)
          Scan the database nodes in parallel, using specified namespace and set filters, and default options.
 CitrusleafClient.ClResultCode scanNode(java.lang.String nodeName, java.lang.String namespace, java.lang.String set, boolean noBinData, int scanPercent, CitrusleafClient.ClOptions opts, CitrusleafClient.ClScanningOptions scanOpts, CitrusleafClient.ScanCallback scanCb, java.lang.Object userData)
          Scan a single database node, using specified namespace and set filters, retrieving records or digests only, as specified.
 CitrusleafClient.ClResultCode set(java.lang.Object key, java.lang.Object value)
          For server nodes configured as "single-bin" only - set record value for specified key, using default namespace, no set name, and default options.
 CitrusleafClient.ClResultCode set(java.lang.Object key, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          For server nodes configured as "single-bin" only - set record value for specified key, using default namespace and no set name.
 CitrusleafClient.ClResultCode set(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Collection<CitrusleafClient.ClBin> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Set record bin values for specified key and bin names.
 CitrusleafClient.ClResultCode set(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.util.Map<java.lang.String,java.lang.Object> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Set record bin values for specified key and bin names.
 CitrusleafClient.ClResultCode set(java.lang.String namespace, java.lang.String set, java.lang.Object key, java.lang.String binName, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Set record bin value for specified key and bin name.
 void setDefaultNamespace(java.lang.String namespace)
          Specify namespace to use in database operation calls that do not have a namespace parameter.
 CitrusleafClient.ClResultCode setDigest(java.lang.String namespace, byte[] digest, CitrusleafClient.ClBin bin, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Set record bin value for specified key digest and bin name.
 CitrusleafClient.ClResultCode setDigest(java.lang.String namespace, byte[] digest, java.util.Collection<CitrusleafClient.ClBin> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Set record bin values for specified key digest and bin names.
 CitrusleafClient.ClResultCode setDigest(java.lang.String namespace, byte[] digest, java.util.Map<java.lang.String,java.lang.Object> bins, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Set record bin values for specified key digest and bin names.
 CitrusleafClient.ClResultCode setDigest(java.lang.String namespace, byte[] digest, java.lang.String binName, java.lang.Object value, CitrusleafClient.ClOptions opts, CitrusleafClient.ClWriteOptions wOpts)
          Set record bin value for specified key digest and bin name.
static void setLogging(CitrusleafClient.ClLogLevel level, CitrusleafClient.LogCallback logCb)
          Set logging level filter and optional log callback implementation.
 
Methods inherited from class com.aerospike.client.AerospikeClient
add, append, close, createIndex, delete, dropIndex, execute, execute, exists, exists, get, get, get, get, getHeader, getHeader, getLargeList, getLargeMap, getLargeSet, getLargeStack, getNodeNames, getNodes, isConnected, operate, prepend, put, query, queryAggregate, register, scanAll, scanNode, scanNode, touch
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CitrusleafClient

public CitrusleafClient()
Constructor, creates CitrusleafClient object and initializes logging framework.

This constructor does not add hosts.


CitrusleafClient

public CitrusleafClient(java.lang.String hostname,
                        int port)
Constructor, combines default constructor CitrusleafClient() and addHost().

Parameters:
hostname - host name
port - host port
Method Detail

setLogging

public static void setLogging(CitrusleafClient.ClLogLevel level,
                              CitrusleafClient.LogCallback logCb)
Set logging level filter and optional log callback implementation.

This method may only be called once, at startup.

Parameters:
level - only show logs at this or more urgent level
logCb - CitrusleafClient.LogCallback implementation, pass null to let Citrusleaf client write logs to System.err

log

public void log(Log.Level level,
                java.lang.String message)
Implementation of com.aerospike.client.Log.Callback

Specified by:
log in interface Log.Callback
Parameters:
level - log level
message - log message

addHost

public CitrusleafClient.ClResultCode addHost(java.lang.String hostname,
                                             int port)
Add a server database host to the client's cluster map.

The following actions occur upon the first invocation of this method:

- create new cluster map
- add host to cluster map
- connect to host server
- request host's list of other nodes in cluster
- add these nodes to cluster map

Further invocations will add hosts to the cluster map if they don't already exist. In most cases, only one addHost() call is necessary. When this call succeeds, the client is ready to process database requests.

Parameters:
hostname - host name
port - host port
Returns:
result status

connect

@Deprecated
public boolean connect()
Deprecated. 

Use AerospikeClient.isConnected().


getNodeNameList

public java.util.List<java.lang.String> getNodeNameList()
Return a list of server nodes in the cluster.

Returns:
list of node names

setDefaultNamespace

public void setDefaultNamespace(java.lang.String namespace)
Specify namespace to use in database operation calls that do not have a namespace parameter.

Parameters:
namespace - namespace to use in calls that have no namepsace parameter

computeDigest

public static byte[] computeDigest(java.lang.String set,
                                   java.lang.Object key)
Generate digest from key and set name.

Parameters:
set - set name
key - record identifier, unique within set
Returns:
unique identifier generated from key and set name

set

public CitrusleafClient.ClResultCode set(java.lang.Object key,
                                         java.lang.Object value)
For server nodes configured as "single-bin" only - set record value for specified key, using default namespace, no set name, and default options.

If the record does not exist, it will be created. If it exists its value is replaced.

Parameters:
key - record identifier, unique within set
value - single-bin value
Returns:
result status

set

public CitrusleafClient.ClResultCode set(java.lang.Object key,
                                         java.lang.Object value,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
For server nodes configured as "single-bin" only - set record value for specified key, using default namespace and no set name.

If the record does not exist, it will be created. If it exists its value is replaced.

Parameters:
key - record identifier, unique within set
value - single-bin value
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

set

public CitrusleafClient.ClResultCode set(java.lang.String namespace,
                                         java.lang.String set,
                                         java.lang.Object key,
                                         java.lang.String binName,
                                         java.lang.Object value,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
Set record bin value for specified key and bin name.

If the record or bin does not exist, it will be created. If the bin exists its value is replaced. Others bins are ignored.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binName - bin name, pass "" if server nodes are configured as "single-bin"
value - bin value
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

set

public CitrusleafClient.ClResultCode set(java.lang.String namespace,
                                         java.lang.String set,
                                         java.lang.Object key,
                                         java.util.Collection<CitrusleafClient.ClBin> bins,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
Set record bin values for specified key and bin names.

If the record or bin does not exist, it will be created. If the bin exists its value is replaced. Others bins are ignored.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Collection
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

set

public CitrusleafClient.ClResultCode set(java.lang.String namespace,
                                         java.lang.String set,
                                         java.lang.Object key,
                                         java.util.Map<java.lang.String,java.lang.Object> bins,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
Set record bin values for specified key and bin names.

If the record or bin does not exist, it will be created. If the bin exists its value is replaced. Others bins are ignored.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Map
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

setDigest

public CitrusleafClient.ClResultCode setDigest(java.lang.String namespace,
                                               byte[] digest,
                                               java.lang.String binName,
                                               java.lang.Object value,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
Set record bin value for specified key digest and bin name.

If the record or bin does not exist, it will be created. If the bin exists its value is replaced. Others bins are ignored.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
binName - bin name, pass "" if server nodes are configured as "single-bin"
value - bin value
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

setDigest

public CitrusleafClient.ClResultCode setDigest(java.lang.String namespace,
                                               byte[] digest,
                                               CitrusleafClient.ClBin bin,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
Set record bin value for specified key digest and bin name.

If the record or bin does not exist, it will be created. If the bin exists its value is replaced. Others bins are ignored.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
bin - bin name/value pair
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

setDigest

public CitrusleafClient.ClResultCode setDigest(java.lang.String namespace,
                                               byte[] digest,
                                               java.util.Collection<CitrusleafClient.ClBin> bins,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
Set record bin values for specified key digest and bin names.

If the record or bin does not exist, it will be created. If the bin exists its value is replaced. Others bins are ignored.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
bins - bin name/value pairs as Collection
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

setDigest

public CitrusleafClient.ClResultCode setDigest(java.lang.String namespace,
                                               byte[] digest,
                                               java.util.Map<java.lang.String,java.lang.Object> bins,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
Set record bin values for specified key digest and bin names.

If the record or bin does not exist, it will be created. If the bin exists its value is replaced. Others bins are ignored.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
bins - bin name/value pairs as Map
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

append

public CitrusleafClient.ClResultCode append(java.lang.Object key,
                                            java.lang.Object value)
For server nodes configured as "single-bin" only - append value to existing record value for specified key, using default namespace, no set name, and default options.

If the record does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
key - record identifier, unique within set
value - value to append
Returns:
result status

append

public CitrusleafClient.ClResultCode append(java.lang.Object key,
                                            java.lang.Object value,
                                            CitrusleafClient.ClOptions opts,
                                            CitrusleafClient.ClWriteOptions wOpts)
For server nodes configured as "single-bin" only - append value to existing record value for specified key, using default namespace and no set name.

If the record does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
key - record identifier, unique within set
value - value to append
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

append

public CitrusleafClient.ClResultCode append(java.lang.String namespace,
                                            java.lang.String set,
                                            java.lang.Object key,
                                            java.lang.String binName,
                                            java.lang.Object value,
                                            CitrusleafClient.ClOptions opts,
                                            CitrusleafClient.ClWriteOptions wOpts)
Append value to existing bin value for specified key.

If the record or bin does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binName - bin name, pass "" if server nodes are configured as "single-bin"
value - value to append
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

append

public CitrusleafClient.ClResultCode append(java.lang.String namespace,
                                            java.lang.String set,
                                            java.lang.Object key,
                                            java.util.Collection<CitrusleafClient.ClBin> bins,
                                            CitrusleafClient.ClOptions opts,
                                            CitrusleafClient.ClWriteOptions wOpts)
Append value to existing bin value for each bin for specified key.

If the record or bin does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Collection
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

append

public CitrusleafClient.ClResultCode append(java.lang.String namespace,
                                            java.lang.String set,
                                            java.lang.Object key,
                                            java.util.Map<java.lang.String,java.lang.Object> bins,
                                            CitrusleafClient.ClOptions opts,
                                            CitrusleafClient.ClWriteOptions wOpts)
Append value to existing bin value for each bin for specified key.

If the record or bin does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Map
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

prepend

public CitrusleafClient.ClResultCode prepend(java.lang.Object key,
                                             java.lang.Object value)
For server nodes configured as "single-bin" only - prepend value to existing record value for specified key, using default namespace, no set name, and default options.

If the record does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
key - record identifier, unique within set
value - value to prepend
Returns:
result status

prepend

public CitrusleafClient.ClResultCode prepend(java.lang.Object key,
                                             java.lang.Object value,
                                             CitrusleafClient.ClOptions opts,
                                             CitrusleafClient.ClWriteOptions wOpts)
For server nodes configured as "single-bin" only - prepend value to existing record value for specified key, using default namespace and no set name.

If the record does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
key - record identifier, unique within set
value - value to prepend
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

prepend

public CitrusleafClient.ClResultCode prepend(java.lang.String namespace,
                                             java.lang.String set,
                                             java.lang.Object key,
                                             java.lang.String binName,
                                             java.lang.Object value,
                                             CitrusleafClient.ClOptions opts,
                                             CitrusleafClient.ClWriteOptions wOpts)
Prepend value to existing bin value for specified key.

If the record or bin does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binName - bin name, pass "" if server nodes are configured as "single-bin"
value - value to prepend
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

prepend

public CitrusleafClient.ClResultCode prepend(java.lang.String namespace,
                                             java.lang.String set,
                                             java.lang.Object key,
                                             java.util.Collection<CitrusleafClient.ClBin> bins,
                                             CitrusleafClient.ClOptions opts,
                                             CitrusleafClient.ClWriteOptions wOpts)
Prepend value to existing bin value for each bin for specified key.

If the record or bin does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Collection
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

prepend

public CitrusleafClient.ClResultCode prepend(java.lang.String namespace,
                                             java.lang.String set,
                                             java.lang.Object key,
                                             java.util.Map<java.lang.String,java.lang.Object> bins,
                                             CitrusleafClient.ClOptions opts,
                                             CitrusleafClient.ClWriteOptions wOpts)
Prepend value to existing bin value for each bin for specified key.

If the record or bin does not exist, it will be created with the specified value.

This call works only if the specified value's type matches the existing value's type, and the type is not an integer (i.e. Integer or Long.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Map
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

add

public CitrusleafClient.ClResultCode add(java.lang.Object key,
                                         java.lang.Object value)
For integer values, and server nodes configured as "single-bin" only - add value to existing record value for specified key, using default namespace, no set name, and default options.

If the record does not exist, it will be created with the specified value.

Parameters:
key - record identifier, unique within set
value - bin value
Returns:
result status

add

public CitrusleafClient.ClResultCode add(java.lang.Object key,
                                         java.lang.Object value,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
For integer values, and server nodes configured as "single-bin" only - add value to existing record value for specified key, using default namespace and no set name.

If the record does not exist, it will be created with the specified value.

Parameters:
key - record identifier, unique within set
value - bin value
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

add

public CitrusleafClient.ClResultCode add(java.lang.String namespace,
                                         java.lang.String set,
                                         java.lang.Object key,
                                         java.lang.String binName,
                                         java.lang.Object value,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for specified key.

If the record or bin does not exist, it will be created with the specified value.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binName - bin name, pass "" if server nodes are configured as "single-bin"
value - bin value
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

add

public CitrusleafClient.ClResultCode add(java.lang.String namespace,
                                         java.lang.String set,
                                         java.lang.Object key,
                                         java.util.Collection<CitrusleafClient.ClBin> bins,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for each bin for specified key.

If the record or bin does not exist, it will be created with the specified value.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Collection
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

add

public CitrusleafClient.ClResultCode add(java.lang.String namespace,
                                         java.lang.String set,
                                         java.lang.Object key,
                                         java.util.Map<java.lang.String,java.lang.Object> bins,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for each bin for specified key.

If the record or bin does not exist, it will be created with the specified value.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Map
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

addAndGet

public CitrusleafClient.ClResult addAndGet(java.lang.String namespace,
                                           java.lang.String set,
                                           java.lang.Object key,
                                           java.util.Collection<CitrusleafClient.ClBin> bins,
                                           CitrusleafClient.ClOptions opts,
                                           CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for each bin for specified key, and return the results.

If the record or bin does not exist, it will be created with the specified value.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Collection
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs with new values

addAndGet

public CitrusleafClient.ClResult addAndGet(java.lang.String namespace,
                                           java.lang.String set,
                                           java.lang.Object key,
                                           java.util.Map<java.lang.String,java.lang.Object> bins,
                                           CitrusleafClient.ClOptions opts,
                                           CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for each bin for specified key, and return the results.

If the record or bin does not exist, it will be created with the specified value.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
bins - bin name/value pairs as Map
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs with new values

addDigest

public CitrusleafClient.ClResultCode addDigest(java.lang.String namespace,
                                               byte[] digest,
                                               java.lang.String binName,
                                               java.lang.Object value,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for specified key digest.

If the record or bin does not exist, it will be created with the specified value.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
binName - bin name, pass "" if server nodes are configured as "single-bin"
value - bin value
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

addDigest

public CitrusleafClient.ClResultCode addDigest(java.lang.String namespace,
                                               byte[] digest,
                                               CitrusleafClient.ClBin bin,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for specified key digest.

If the record or bin does not exist, it will be created with the specified value.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
bin - bin name/value pair
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

addDigest

public CitrusleafClient.ClResultCode addDigest(java.lang.String namespace,
                                               byte[] digest,
                                               java.util.Collection<CitrusleafClient.ClBin> bins,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for each bin for specified key digest.

If the record or bin does not exist, it will be created with the specified value.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
bins - bin name/value pairs as Collection
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

addDigest

public CitrusleafClient.ClResultCode addDigest(java.lang.String namespace,
                                               byte[] digest,
                                               java.util.Map<java.lang.String,java.lang.Object> bins,
                                               CitrusleafClient.ClOptions opts,
                                               CitrusleafClient.ClWriteOptions wOpts)
For integer values only - add value to existing bin value for each bin for specified key digest.

If the record or bin does not exist, it will be created with the specified value.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
bins - bin name/value pairs as Map
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

delete

public CitrusleafClient.ClResultCode delete(java.lang.Object key,
                                            CitrusleafClient.ClOptions opts,
                                            CitrusleafClient.ClWriteOptions wOpts)
Delete record for specified key, using default namespace and no set name.

Parameters:
key - record identifier, unique within set
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

delete

public CitrusleafClient.ClResultCode delete(java.lang.String namespace,
                                            java.lang.String set,
                                            java.lang.Object key,
                                            CitrusleafClient.ClOptions opts,
                                            CitrusleafClient.ClWriteOptions wOpts)
Delete record for specified key.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

deleteDigest

public CitrusleafClient.ClResultCode deleteDigest(java.lang.String namespace,
                                                  byte[] digest,
                                                  CitrusleafClient.ClOptions opts,
                                                  CitrusleafClient.ClWriteOptions wOpts)
Delete record for specified key digest.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
result status

get

public java.lang.Object get(java.lang.Object key)
For server nodes configured as "single-bin" only - get record value for specified key, using default namespace, no set name, and default options.

Parameters:
key - record identifier, unique within set
Returns:
CitrusleafClient.ClResult containing single-bin value

get

public CitrusleafClient.ClResult get(java.lang.String namespace,
                                     java.lang.String set,
                                     java.lang.Object key,
                                     java.lang.String binName,
                                     CitrusleafClient.ClOptions opts)
Get bin value for specified key and bin name.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binName - bin name filter, pass "" if server nodes are configured as "single-bin"
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin value

get

public CitrusleafClient.ClResult get(java.lang.String namespace,
                                     java.lang.String set,
                                     java.lang.Object key,
                                     java.lang.String[] binNames,
                                     CitrusleafClient.ClOptions opts)
Get bin name/value pairs for specified key and list of bin names.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binNames - bin names filter as array
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs

get

public CitrusleafClient.ClResult get(java.lang.String namespace,
                                     java.lang.String set,
                                     java.lang.Object key,
                                     java.util.Collection<java.lang.String> binNames,
                                     CitrusleafClient.ClOptions opts)
Get bin name/value pairs for specified key and list of bin names.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binNames - bin names filter as Collection
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs

getAll

public CitrusleafClient.ClResult getAll(java.lang.String namespace,
                                        java.lang.String set,
                                        java.lang.Object key,
                                        CitrusleafClient.ClOptions opts)
Get all bin name/value pairs for specified key.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs

getWithTouch

public CitrusleafClient.ClResult getWithTouch(java.lang.String namespace,
                                              java.lang.String set,
                                              java.lang.Object key,
                                              java.util.Collection<java.lang.String> binNames,
                                              int expiration,
                                              CitrusleafClient.ClOptions opts)
Get bin name/value pairs for specified key and list of bin names, and if the record exists, reset record time to expiration.

This operation will increment the record generation.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
binNames - bin names filter as Collection
expiration - new record expiration (see CitrusleafClient.ClWriteOptions.expiration)
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs

batchGet

public CitrusleafClient.ClResult[] batchGet(java.lang.String namespace,
                                            java.lang.String set,
                                            java.util.Collection<java.lang.Object> keys,
                                            java.lang.String binName,
                                            CitrusleafClient.ClOptions opts)
Batch multiple get() requests into a single call.

Elements of keys are positionally matched with elements of result array.

Parameters:
namespace - namespace
set - optional set name
keys - batch of keys as Collection
binName - bin name filter, pass "" if server nodes are configured as "single-bin"
opts - transaction policy attributes, pass null to use defaults
Returns:
result array where each element contains bin name/value pairs

batchGet

public CitrusleafClient.ClResult[] batchGet(java.lang.String namespace,
                                            java.lang.String set,
                                            java.util.Collection<java.lang.Object> keys,
                                            java.util.Collection<java.lang.String> binNames,
                                            CitrusleafClient.ClOptions opts)
Batch multiple get() requests into a single call.

Elements of keys are positionally matched with elements of result array.

Parameters:
namespace - namespace
set - optional set name
keys - batch of keys as Collection
binNames - bin names filter as Collection
opts - transaction policy attributes, pass null to use defaults
Returns:
result array where each element contains bin name/value pairs

batchGetAll

public CitrusleafClient.ClResult[] batchGetAll(java.lang.String namespace,
                                               java.lang.String set,
                                               java.util.Collection<java.lang.Object> keys,
                                               CitrusleafClient.ClOptions opts)
Batch multiple getAll() requests into a single call.

Elements of keys are positionally matched with elements of result array.

Parameters:
namespace - namespace
set - optional set name
keys - batch of keys as Collection
opts - transaction policy attributes, pass null to use defaults
Returns:
result array where each element contains bin name/value pairs

getDigest

public CitrusleafClient.ClResult getDigest(java.lang.String namespace,
                                           byte[] digest,
                                           java.lang.String binName,
                                           CitrusleafClient.ClOptions opts)
Get bin value for specified key digest and bin name.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
binName - bin name filter, pass "" if server nodes are configured as "single-bin"
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin value

getDigest

public CitrusleafClient.ClResult getDigest(java.lang.String namespace,
                                           byte[] digest,
                                           java.util.Collection<java.lang.String> binNames,
                                           CitrusleafClient.ClOptions opts)
Get bin name/value pairs for specified key digest and list of bin names.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
binNames - bin names filter as Collection
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs

getAllDigest

public CitrusleafClient.ClResult getAllDigest(java.lang.String namespace,
                                              byte[] digest,
                                              CitrusleafClient.ClOptions opts)
Get all bin name/value pairs for specified key digest.

Non-Digest database methods send the normal key and set name to the server which converts them to a digest. Digest methods send the digest directly.

Parameters:
namespace - namespace
digest - unique identifier generated from key and set name
opts - transaction policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult containing bin name/value pairs

exists

public CitrusleafClient.ClResultCode exists(java.lang.Object key)
Check if specified key exists, using default namespace, no set name, and default options.

Parameters:
key - record identifier, unique within set
Returns:
result status

exists

public CitrusleafClient.ClResultCode exists(java.lang.String namespace,
                                            java.lang.String set,
                                            java.lang.Object key,
                                            CitrusleafClient.ClOptions opts)
Check if specified key exists.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
opts - transaction policy attributes, pass null to use defaults
Returns:
result status

batchExists

public CitrusleafClient.ClResult[] batchExists(java.lang.String namespace,
                                               java.lang.String set,
                                               java.util.Collection<java.lang.Object> keys,
                                               CitrusleafClient.ClOptions opts)
Batch multiple exists() requests into a single call.

Elements of keys are positionally matched with elements of result array.

Parameters:
namespace - namespace
set - optional set name
keys - batch of keys as Collection
opts - transaction policy attributes, pass null to use defaults
Returns:
result array where each element indicates whether its corresponding key exists

scan

@Deprecated
public CitrusleafClient.ClResult scan(java.lang.String namespace,
                                                 CitrusleafClient.ClOptions opts,
                                                 CitrusleafClient.ScanCallback scanCb,
                                                 java.lang.Object userData)
Deprecated. 

Scan the database, retrieving all records in specified namespace.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
opts - transaction policy attributes, pass null to use defaults
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
CitrusleafClient.ClResult for final record

scan

@Deprecated
public CitrusleafClient.ClResult scan(java.lang.String namespace,
                                                 java.lang.String set,
                                                 CitrusleafClient.ClOptions opts,
                                                 CitrusleafClient.ScanCallback scanCb,
                                                 java.lang.Object userData)
Deprecated. 

Scan the database, retrieving all records in specified namespace.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
set - set name, not supported as scan filter
opts - transaction policy attributes, pass null to use defaults
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
CitrusleafClient.ClResult for final record

scan

@Deprecated
public CitrusleafClient.ClResult scan(java.lang.String namespace,
                                                 CitrusleafClient.ClOptions opts,
                                                 CitrusleafClient.ScanCallback scanCb,
                                                 java.lang.Object userData,
                                                 boolean noBinData)
Deprecated. 

Scan the database using specified namespace filter, retrieving records or digests only, as specified.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
opts - transaction policy attributes, pass null to use defaults
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
CitrusleafClient.ClResult for final record

scan

@Deprecated
public CitrusleafClient.ClResult scan(java.lang.String namespace,
                                                 java.lang.String set,
                                                 CitrusleafClient.ClOptions opts,
                                                 CitrusleafClient.ScanCallback scanCb,
                                                 java.lang.Object userData,
                                                 boolean noBinData)
Deprecated. 

Scan the database using specified namespace filter, retrieving records or digests only, as specified.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
set - set name, not supported as scan filter
opts - transaction policy attributes, pass null to use defaults
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
noBinData - true to retrieve digests only, false to retrieve bin data
Returns:
CitrusleafClient.ClResult for final record

scanNode

public CitrusleafClient.ClResultCode scanNode(java.lang.String nodeName,
                                              java.lang.String namespace,
                                              java.lang.String set,
                                              boolean noBinData,
                                              int scanPercent,
                                              CitrusleafClient.ClOptions opts,
                                              CitrusleafClient.ClScanningOptions scanOpts,
                                              CitrusleafClient.ScanCallback scanCb,
                                              java.lang.Object userData)
Scan a single database node, using specified namespace and set filters, retrieving records or digests only, as specified.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
nodeName - node to scan
namespace - namespace
set - set name, pass null to retrieve all records in the namespace
noBinData - true to retrieve digests only, false to retrieve bin data
scanPercent - fraction of data to scan - not yet supported
opts - transaction policy attributes, pass null to use defaults
scanOpts - parallel scan policy attributes, pass null to use defaults
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
result status

scan

public CitrusleafClient.ClResultCode scan(java.lang.String namespace,
                                          java.lang.String set,
                                          CitrusleafClient.ScanCallback scanCb,
                                          java.lang.Object userData)
Scan the database nodes in parallel, using specified namespace and set filters, and default options, returning a single result code.

This call is the same as scanAllNodes() but returns only one result code.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
set - set name, pass null to retrieve all records in the namespace
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
result status, OK if all nodes succeeded, else first error code encountered

scanAllNodes

public java.util.Map<java.lang.String,CitrusleafClient.ClResultCode> scanAllNodes(java.lang.String namespace,
                                                                                  java.lang.String set,
                                                                                  CitrusleafClient.ScanCallback scanCb,
                                                                                  java.lang.Object userData)
Scan the database nodes in parallel, using specified namespace and set filters, and default options.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
set - set name, pass null to retrieve all records in the namespace
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
result status for each node

scanAllNodes

public java.util.Map<java.lang.String,CitrusleafClient.ClResultCode> scanAllNodes(java.lang.String namespace,
                                                                                  java.lang.String set,
                                                                                  CitrusleafClient.ClOptions opts,
                                                                                  CitrusleafClient.ClScanningOptions scanOpts,
                                                                                  CitrusleafClient.ScanCallback scanCb,
                                                                                  java.lang.Object userData)
Scan the database nodes in parallel, using specified namespace and set filters.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
set - set name, pass null to retrieve all records in the namespace
opts - transaction policy attributes, pass null to use defaults
scanOpts - parallel scan policy attributes, pass null to use defaults
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
result status for each node

scanAllNodes

public java.util.Map<java.lang.String,CitrusleafClient.ClResultCode> scanAllNodes(java.lang.String namespace,
                                                                                  java.lang.String set,
                                                                                  boolean noBinData,
                                                                                  int scanPercent,
                                                                                  CitrusleafClient.ClOptions opts,
                                                                                  CitrusleafClient.ClScanningOptions scanOpts,
                                                                                  CitrusleafClient.ScanCallback scanCb,
                                                                                  java.lang.Object userData)
Scan the database nodes in parallel, using specified namespace and set filters, retrieving records or digests only, as specified.

This call will block until the scan is complete - callbacks are made within the scope of this call.

Parameters:
namespace - namespace
set - set name, pass null to retrieve all records in the namespace
noBinData - true to retrieve digests only, false to retrieve bin data
scanPercent - fraction of data to scan - not yet supported
opts - transaction policy attributes, pass null to use defaults
scanOpts - parallel scan policy attributes, pass null to use defaults
scanCb - CitrusleafClient.ScanCallback implementation
userData - pass-through user-defined data
Returns:
result status for each node

operate

public CitrusleafClient.ClResult operate(java.lang.String namespace,
                                         java.lang.String set,
                                         java.lang.Object key,
                                         java.util.Collection<java.lang.String> readBinNames,
                                         java.util.Collection<CitrusleafClient.ClBin> writeBins,
                                         CitrusleafClient.ClOptions opts,
                                         CitrusleafClient.ClWriteOptions wOpts)
Combine get() and set() operations for a specified record.

Parameters:
namespace - namespace
set - optional set name
key - record identifier, unique within set
readBinNames - bin names filter for read
writeBins - bin name/value pairs to write
opts - transaction policy attributes, pass null to use defaults
wOpts - write policy attributes, pass null to use defaults
Returns:
CitrusleafClient.ClResult for read, containing bin name/value pairs

ClLog

public static void ClLog(CitrusleafClient.ClLogLevel logLevel,
                         java.lang.String msg)