public class ExecuteOptions
extends java.lang.Object
| Constructor | Description |
|---|---|
ExecuteOptions() |
| Modifier and Type | Method | Description |
|---|---|---|
Consistency |
getConsistency() |
Gets the last set execution consistency.
|
Durability |
getDurability() |
Gets the last set execution durability.
|
java.math.MathContext |
getMathContext() |
Returns the
MathContext used for BigDecimal and
BigInteger operations. |
int |
getMaxConcurrentRequests() |
Returns the maximum number of concurrent requests.
|
long |
getMaxMemoryConsumption() |
Get the maximum number of memory bytes that may be consumed by the
statement at the client for blocking operations, such as duplicate
elimination (which may be required due to the use of an index on an
array or map) and sorting (sorting by distance when a query contains
a geo_near() function).
|
java.lang.String |
getNamespace() |
Returns the namespace to use for the query, null if not set.
|
int |
getResultsBatchSize() |
Returns the number of results per request.
|
long |
getTimeout() |
Gets the timeout, which is an upper bound on the time interval for
processing the read or write operations.
|
java.util.concurrent.TimeUnit |
getTimeoutUnit() |
Gets the unit of the timeout parameter, and may
be
null only if getTimeout() returns zero. |
ExecuteOptions |
setConsistency(Consistency consistency) |
Sets the execution consistency.
|
ExecuteOptions |
setDurability(Durability durability) |
Sets the execution durability.
|
ExecuteOptions |
setMathContext(java.math.MathContext mathContext) |
Sets the
MathContext used for BigDecimal and
BigInteger operations. |
ExecuteOptions |
setMaxConcurrentRequests(int maxConcurrentRequests) |
Sets the maximum number of concurrent requests.
|
void |
setMaxMemoryConsumption(long v) |
Set the maximum number of memory bytes that may be consumed by the
statement at the client for blocking operations, such as duplicate
elimination (which may be required due to the use of an index on an
array or map) and sorting (sorting by distance when a query contains
a geo_near() function).
|
ExecuteOptions |
setNamespace(java.lang.String namespace) |
Sets the namespace to use for the query.
|
ExecuteOptions |
setResultsBatchSize(int resultsBatchSize) |
Sets the number of results per request.
|
ExecuteOptions |
setTimeout(long timeout,
java.util.concurrent.TimeUnit timeoutUnit) |
The
timeout parameter is an upper bound on the time interval for
processing the operation. |
public ExecuteOptions setConsistency(Consistency consistency)
public Consistency getConsistency()
public ExecuteOptions setDurability(Durability durability)
public Durability getDurability()
public ExecuteOptions setTimeout(long timeout, java.util.concurrent.TimeUnit timeoutUnit)
timeout parameter is an upper bound on the time interval for
processing the operation. A best effort is made not to exceed the
specified limit. If zero, the default request timeout is used.
If timeout is not 0, the timeoutUnit parameter must not
be null.
timeout - the timeout value to usetimeoutUnit - the TimeUnit used by the
timeout parameter or nullpublic long getTimeout()
default request timeout is used.public java.util.concurrent.TimeUnit getTimeoutUnit()
null only if getTimeout() returns zero.public int getMaxConcurrentRequests()
public ExecuteOptions setMaxConcurrentRequests(int maxConcurrentRequests)
public int getResultsBatchSize()
public ExecuteOptions setResultsBatchSize(int resultsBatchSize)
public java.math.MathContext getMathContext()
MathContext used for BigDecimal and
BigInteger operations. MathContext.DECIMAL32 is used by
default.public ExecuteOptions setMathContext(java.math.MathContext mathContext)
MathContext used for BigDecimal and
BigInteger operations. MathContext.DECIMAL32 is used by
default.public ExecuteOptions setNamespace(java.lang.String namespace)
public java.lang.String getNamespace()
public void setMaxMemoryConsumption(long v)
public long getMaxMemoryConsumption()
Copyright (c) 2011, 2018 Oracle and/or its affiliates. All rights reserved.