@NotThreadSafe public class Put extends Mutation
DistributedStorage
.Constructor and Description |
---|
Put(Key partitionKey)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use
newBuilder()
instead |
Put(Key partitionKey,
Key clusteringKey)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use
newBuilder()
instead |
Put(Put put)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use
newBuilder(Put) instead |
Modifier and Type | Method and Description |
---|---|
void |
accept(OperationVisitor v)
Access the specified visitor
|
boolean |
containsColumn(java.lang.String columnName)
Indicates whether the list of put values contains the specified column.
|
boolean |
equals(java.lang.Object o)
Indicates whether some other object is "equal to" this object.
|
Put |
forNamespace(java.lang.String namespace)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
forTable(java.lang.String tableName)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
long |
getBigIntValue(java.lang.String columnName)
Returns the BIGINT value of the specified column added to the list of put values.
|
java.nio.ByteBuffer |
getBlobValue(java.lang.String columnName)
Returns the BLOB value of the specified column added to the list of put values as a ByteBuffer
type.
|
java.nio.ByteBuffer |
getBlobValueAsByteBuffer(java.lang.String columnName)
Returns the BLOB value of the specified column added to the list of put values as a ByteBuffer
type.
|
byte[] |
getBlobValueAsBytes(java.lang.String columnName)
Returns the BLOB value of the specified column added to the list of put values as a byte array
type.
|
boolean |
getBooleanValue(java.lang.String columnName)
Returns the BOOLEAN value of the specified column added to the list of put values.
|
java.util.Map<java.lang.String,Column<?>> |
getColumns()
Returns a map of
Column s. |
java.util.Set<java.lang.String> |
getContainedColumnNames()
Returns a set of the contained column names for the values added to the list of put values.
|
double |
getDoubleValue(java.lang.String columnName)
Returns the DOUBLE value of the specified column added to the list of put values.
|
float |
getFloatValue(java.lang.String columnName)
Returns the FLOAT value of the specified column added to the list of put values.
|
int |
getIntValue(java.lang.String columnName)
Returns the INT value of the specified column added to the list of put values.
|
java.lang.String |
getTextValue(java.lang.String columnName)
Returns the TEXT value of the specified column added to the list of put values.
|
java.lang.Object |
getValueAsObject(java.lang.String columnName)
Returns the value of the specified column added to the list of put values as an Object type.
|
java.util.Map<java.lang.String,Value<?>> |
getValues()
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0
|
int |
hashCode() |
boolean |
isNullValue(java.lang.String columnName)
Indicates whether the value of the specified column added to the list of put values is NULL.
|
static PutBuilder.Namespace |
newBuilder()
Build a
Put operation using a builder. |
static PutBuilder.BuildableFromExisting |
newBuilder(Put put)
Build a
Put operation from an existing Put object using a builder. |
java.lang.String |
toString() |
Put |
withBigIntValue(java.lang.String columnName,
long value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withBigIntValue(java.lang.String columnName,
java.lang.Long value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withBlobValue(java.lang.String columnName,
byte[] value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withBlobValue(java.lang.String columnName,
java.nio.ByteBuffer value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withBooleanValue(java.lang.String columnName,
boolean value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withBooleanValue(java.lang.String columnName,
java.lang.Boolean value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withCondition(MutationCondition condition)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withConsistency(Consistency consistency)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withDoubleValue(java.lang.String columnName,
double value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withDoubleValue(java.lang.String columnName,
java.lang.Double value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withFloatValue(java.lang.String columnName,
float value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withFloatValue(java.lang.String columnName,
java.lang.Float value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withIntValue(java.lang.String columnName,
int value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withIntValue(java.lang.String columnName,
java.lang.Integer value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withTextValue(java.lang.String columnName,
java.lang.String value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(Column<?> column)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
boolean booleanValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
byte[] blobValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
java.nio.ByteBuffer blobValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
double doubleValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
float floatValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
int intValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
long bigIntValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(java.lang.String columnName,
java.lang.String textValue)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValue(Value<?> value)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0. Use the setter method of the
Put builder instead; to create a Put builder, use
newBuilder() |
Put |
withValues(java.util.Collection<Value<?>> values)
Deprecated.
As of release 3.6.0. Will be removed in release 5.0.0
|
getCondition
forFullTableName, forNamespace, forTable, getClusteringKey, getConsistency, getPartitionKey
@Deprecated public Put(Key partitionKey)
newBuilder()
insteadPut
with the specified partition Key
.partitionKey
- a partition Key
(it might be composed of multiple values)@Deprecated public Put(Key partitionKey, Key clusteringKey)
newBuilder()
insteadpartitionKey
- a partition Key
(it might be composed of multiple values)clusteringKey
- a clustering Key
(it might be composed of multiple values)@Deprecated public Put(Put put)
newBuilder(Put)
insteadput
- a Putpublic static PutBuilder.Namespace newBuilder()
Put
operation using a builder.Put
operation builderpublic static PutBuilder.BuildableFromExisting newBuilder(Put put)
Put
operation from an existing Put
object using a builder. The builder
will be parametrized by default with all the existing Put
object attributesput
- an existing Put
operationPut
operation builder@Deprecated public Put withValue(Value<?> value)
newBuilder()
Value
to the list of put values.value
- a Value
to put@Deprecated public Put withValue(java.lang.String columnName, boolean booleanValue)
newBuilder()
columnName
- a column name of the valuebooleanValue
- a BOOLEAN value to put@Deprecated public Put withBooleanValue(java.lang.String columnName, boolean value)
newBuilder()
columnName
- a column name of the valuevalue
- a BOOLEAN value to put@Deprecated public Put withBooleanValue(java.lang.String columnName, @Nullable java.lang.Boolean value)
newBuilder()
columnName
- a column name of the valuevalue
- a BOOLEAN value to put@Deprecated public Put withValue(java.lang.String columnName, int intValue)
newBuilder()
columnName
- a column name of the valueintValue
- a INT value to put@Deprecated public Put withIntValue(java.lang.String columnName, int value)
newBuilder()
columnName
- a column name of the valuevalue
- a INT value to put@Deprecated public Put withIntValue(java.lang.String columnName, @Nullable java.lang.Integer value)
newBuilder()
columnName
- a column name of the valuevalue
- a INT value to put@Deprecated public Put withValue(java.lang.String columnName, long bigIntValue)
newBuilder()
columnName
- a column name of the valuebigIntValue
- a BIGINT value to put@Deprecated public Put withBigIntValue(java.lang.String columnName, long value)
newBuilder()
columnName
- a column name of the valuevalue
- a BIGINT value to put@Deprecated public Put withBigIntValue(java.lang.String columnName, @Nullable java.lang.Long value)
newBuilder()
columnName
- a column name of the valuevalue
- a BIGINT value to put@Deprecated public Put withValue(java.lang.String columnName, float floatValue)
newBuilder()
columnName
- a column name of the valuefloatValue
- a value to put@Deprecated public Put withFloatValue(java.lang.String columnName, float value)
newBuilder()
columnName
- a column name of the valuevalue
- a FLOAT value to put@Deprecated public Put withFloatValue(java.lang.String columnName, @Nullable java.lang.Float value)
newBuilder()
columnName
- a column name of the valuevalue
- a FLOAT value to put@Deprecated public Put withValue(java.lang.String columnName, double doubleValue)
newBuilder()
columnName
- a column name of the valuedoubleValue
- a DOUBLE value to put@Deprecated public Put withDoubleValue(java.lang.String columnName, double value)
newBuilder()
columnName
- a column name of the valuevalue
- a DOUBLE value to put@Deprecated public Put withDoubleValue(java.lang.String columnName, @Nullable java.lang.Double value)
newBuilder()
columnName
- a column name of the valuevalue
- a DOUBLE value to put@Deprecated public Put withValue(java.lang.String columnName, @Nullable java.lang.String textValue)
newBuilder()
columnName
- a column name of the valuetextValue
- a TEXT value to put@Deprecated public Put withTextValue(java.lang.String columnName, @Nullable java.lang.String value)
newBuilder()
columnName
- a column name of the valuevalue
- a TEXT value to put@Deprecated public Put withValue(java.lang.String columnName, @Nullable byte[] blobValue)
newBuilder()
columnName
- a column name of the valueblobValue
- a BLOB value to put@Deprecated public Put withBlobValue(java.lang.String columnName, @Nullable byte[] value)
newBuilder()
columnName
- a column name of the valuevalue
- a BLOB value to put@Deprecated public Put withValue(java.lang.String columnName, @Nullable java.nio.ByteBuffer blobValue)
newBuilder()
columnName
- a column name of the valueblobValue
- a BLOB value to put@Deprecated public Put withBlobValue(java.lang.String columnName, @Nullable java.nio.ByteBuffer value)
newBuilder()
columnName
- a column name of the valuevalue
- a BLOB value to put@Deprecated public Put withValues(java.util.Collection<Value<?>> values)
Value
s to the list of put values.values
- a collection of Value
s to put@Deprecated public Put withValue(Column<?> column)
newBuilder()
This method is primarily for internal use. Breaking changes can and will be introduced to this method. Users should not depend on it.
column
- a column to put@Deprecated public java.util.Map<java.lang.String,Value<?>> getValues()
Value
s.Value
spublic java.util.Map<java.lang.String,Column<?>> getColumns()
Column
s.
This method is primarily for internal use. Breaking changes can and will be introduced to this method. Users should not depend on it.
Column
spublic boolean isNullValue(java.lang.String columnName)
columnName
- a column name of the valuepublic boolean getBooleanValue(java.lang.String columnName)
Note that, due to its signature, this method cannot return null. If the value is NULL, it
will return 0. If this doesn't work for you, either call isNullValue(String)
before
calling this method, or use getValueAsObject(String)
instead.
columnName
- a column name of the valuepublic int getIntValue(java.lang.String columnName)
Note that, due to its signature, this method cannot return null. If the value is NULL, it
will return 0. If this doesn't work for you, either call isNullValue(String)
before
calling this method, or use getValueAsObject(String)
instead.
columnName
- a column name of the valuepublic long getBigIntValue(java.lang.String columnName)
Note that, due to its signature, this method cannot return null. If the value is NULL, it
will return 0. If this doesn't work for you, either call isNullValue(String)
before
calling this method, or use getValueAsObject(String)
instead.
columnName
- a column name of the valuepublic float getFloatValue(java.lang.String columnName)
Note that, due to its signature, this method cannot return null. If the value is NULL, it
will return 0.0. If this doesn't work for you, either call isNullValue(String)
before
calling this method, or use getValueAsObject(String)
instead.
columnName
- a column name of the valuepublic double getDoubleValue(java.lang.String columnName)
Note that, due to its signature, this method cannot return null. If the value is NULL, it
will return 0.0. If this doesn't work for you, either call isNullValue(String)
before
calling this method, or use getValueAsObject(String)
instead.
columnName
- a column name of the value@Nullable public java.lang.String getTextValue(java.lang.String columnName)
columnName
- a column name of the value@Nullable public java.nio.ByteBuffer getBlobValue(java.lang.String columnName)
columnName
- a column name of the value@Nullable public java.nio.ByteBuffer getBlobValueAsByteBuffer(java.lang.String columnName)
columnName
- a column name of the value@Nullable public byte[] getBlobValueAsBytes(java.lang.String columnName)
columnName
- a column name of the value@Nullable public java.lang.Object getValueAsObject(java.lang.String columnName)
If the columns is a BOOLEAN type, it returns a Boolean
object. If the columns is an
INT type, it returns an Integer
object. If the columns is a BIGINT type, it returns a
LONG
object. If the columns is a FLOAT type, it returns a FLOAT
object. If the
columns is a DOUBLE type, it returns a DOUBLE
object. If the columns is a TEXT type, it
returns a String
object. If the columns is a BLOB type, it returns a ByteBuffer
object.
columnName
- a column name of the valuepublic boolean containsColumn(java.lang.String columnName)
columnName
- a column name of the valuepublic java.util.Set<java.lang.String> getContainedColumnNames()
@Deprecated public Put forNamespace(java.lang.String namespace)
newBuilder()
Operation
forNamespace
in class Operation
namespace
- target namespace for this operation@Deprecated public Put forTable(java.lang.String tableName)
newBuilder()
Operation
@Deprecated public Put withConsistency(Consistency consistency)
newBuilder()
Operation
withConsistency
in class Operation
consistency
- consistency level to setpublic void accept(OperationVisitor v)
Operation
@Deprecated public Put withCondition(MutationCondition condition)
newBuilder()
Mutation
MutationCondition
withCondition
in class Mutation
condition
- a MutationCondition
public boolean equals(java.lang.Object o)
Put
and