Package | Description |
---|---|
com.datastax.driver.core |
The main package for the DataStax Java driver for Cassandra.
|
com.datastax.driver.core.exceptions |
Exceptions thrown by the DataStax Java driver for Cassandra.
|
com.datastax.driver.core.querybuilder |
A CQL3 query builder.
|
com.datastax.driver.core.schemabuilder |
A CQL3 schema builder.
|
Modifier and Type | Field and Description |
---|---|
static ProtocolVersion |
ProtocolVersion.NEWEST_BETA
The most recent beta protocol version supported by the driver.
|
static ProtocolVersion |
ProtocolVersion.NEWEST_SUPPORTED
The most recent protocol version supported by the driver.
|
Modifier and Type | Field and Description |
---|---|
static Map<ProtocolVersion,Map<String,Integer>> |
PoolingOptions.DEFAULTS
The default values for connection options, that depend on the native protocol version.
|
Modifier and Type | Method and Description |
---|---|
static ProtocolVersion |
ProtocolVersion.fromInt(int i)
Returns the value matching an integer version.
|
ProtocolVersion |
ProtocolVersion.getLowerSupported()
Returns the highest supported version that is lower than this version.
|
ProtocolVersion |
ProtocolOptions.getProtocolVersion()
The protocol version used by the Cluster instance.
|
static ProtocolVersion |
ProtocolVersion.valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ProtocolVersion[] |
ProtocolVersion.values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
Modifier and Type | Method and Description |
---|---|
abstract T |
TypeCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion)
Deserialize the given
ByteBuffer instance according to the CQL type handled by this
codec. |
Boolean |
TypeCodec.PrimitiveBooleanCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Byte |
TypeCodec.PrimitiveByteCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Short |
TypeCodec.PrimitiveShortCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Integer |
TypeCodec.PrimitiveIntCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Long |
TypeCodec.PrimitiveLongCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Float |
TypeCodec.PrimitiveFloatCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Double |
TypeCodec.PrimitiveDoubleCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
C |
TypeCodec.AbstractCollectionCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Map<K,V> |
TypeCodec.AbstractMapCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
T |
TypeCodec.AbstractUDTCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
T |
TypeCodec.AbstractTupleCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
protected abstract T |
TypeCodec.AbstractTupleCodec.deserializeAndSetField(ByteBuffer input,
T target,
int index,
ProtocolVersion protocolVersion)
Deserialize an individual field and set it on an object, as part of deserializing the whole
object from a CQL tuple (see
TypeCodec.AbstractTupleCodec.deserialize(ByteBuffer, ProtocolVersion) ). |
protected abstract T |
TypeCodec.AbstractUDTCodec.deserializeAndSetField(ByteBuffer input,
T target,
String fieldName,
ProtocolVersion protocolVersion)
Deserialize an individual field and set it on an object, as part of deserializing the whole
object from a CQL UDT (see
TypeCodec.AbstractUDTCodec.deserialize(ByteBuffer, ProtocolVersion) ). |
abstract boolean |
TypeCodec.PrimitiveBooleanCodec.deserializeNoBoxing(ByteBuffer v,
ProtocolVersion protocolVersion) |
abstract byte |
TypeCodec.PrimitiveByteCodec.deserializeNoBoxing(ByteBuffer v,
ProtocolVersion protocolVersion) |
abstract short |
TypeCodec.PrimitiveShortCodec.deserializeNoBoxing(ByteBuffer v,
ProtocolVersion protocolVersion) |
abstract int |
TypeCodec.PrimitiveIntCodec.deserializeNoBoxing(ByteBuffer v,
ProtocolVersion protocolVersion) |
abstract long |
TypeCodec.PrimitiveLongCodec.deserializeNoBoxing(ByteBuffer v,
ProtocolVersion protocolVersion) |
abstract float |
TypeCodec.PrimitiveFloatCodec.deserializeNoBoxing(ByteBuffer v,
ProtocolVersion protocolVersion) |
abstract double |
TypeCodec.PrimitiveDoubleCodec.deserializeNoBoxing(ByteBuffer v,
ProtocolVersion protocolVersion) |
Map<String,ByteBuffer> |
SimpleStatement.getNamedValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
abstract Map<String,ByteBuffer> |
RegularStatement.getNamedValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
The named values to use for this statement.
|
ByteBuffer |
BoundStatement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
The routing key for this bound query.
|
ByteBuffer |
SimpleStatement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the routing key for the query.
|
ByteBuffer |
StatementWrapper.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
ByteBuffer |
BatchStatement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
abstract ByteBuffer |
Statement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the routing key (in binary raw form) to use for token aware routing of this query.
|
ByteBuffer[] |
SimpleStatement.getValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
abstract ByteBuffer[] |
RegularStatement.getValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
The positional values to use for this statement.
|
static TupleType |
TupleType.of(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry,
DataType... types)
Creates a "disconnected" tuple type (you should prefer
cluster.getMetadata().newTupleType(...) whenever
possible). |
static ByteBuffer |
CodecUtils.pack(ByteBuffer[] buffers,
int elements,
ProtocolVersion version)
Utility method that "packs" together a list of
ByteBuffer s containing serialized
collection elements. |
static int |
CodecUtils.readSize(ByteBuffer input,
ProtocolVersion version)
Utility method that reads a size value.
|
static ByteBuffer |
CodecUtils.readValue(ByteBuffer input,
ProtocolVersion version)
Utility method that reads a value.
|
int |
BoundStatement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the number of bytes required to encode this statement.
|
int |
StatementWrapper.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
int |
BatchStatement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
int |
RegularStatement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
int |
Statement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the number of bytes required to encode this statement.
|
ByteBuffer |
TypeCodec.PrimitiveBooleanCodec.serialize(Boolean value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.PrimitiveByteCodec.serialize(Byte value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.AbstractCollectionCodec.serialize(C value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.PrimitiveDoubleCodec.serialize(Double value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.PrimitiveFloatCodec.serialize(Float value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.PrimitiveIntCodec.serialize(Integer value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.PrimitiveLongCodec.serialize(Long value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.AbstractMapCodec.serialize(Map<K,V> value,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
Token.serialize(ProtocolVersion protocolVersion)
Returns the serialized form of the current token, using the appropriate codec depending on the
partitioner in use and the CQL datatype for the token.
|
ByteBuffer |
TypeCodec.PrimitiveShortCodec.serialize(Short value,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
TypeCodec.serialize(T value,
ProtocolVersion protocolVersion)
Serialize the given value according to the CQL type handled by this codec.
|
ByteBuffer |
TypeCodec.AbstractUDTCodec.serialize(T value,
ProtocolVersion protocolVersion) |
ByteBuffer |
TypeCodec.AbstractTupleCodec.serialize(T value,
ProtocolVersion protocolVersion) |
protected abstract ByteBuffer |
TypeCodec.AbstractTupleCodec.serializeField(T source,
int index,
ProtocolVersion protocolVersion)
Serialize an individual field in an object, as part of serializing the whole object to a CQL
tuple (see
TypeCodec.AbstractTupleCodec.serialize(Object, ProtocolVersion) ). |
protected abstract ByteBuffer |
TypeCodec.AbstractUDTCodec.serializeField(T source,
String fieldName,
ProtocolVersion protocolVersion)
Serialize an individual field in an object, as part of serializing the whole object to a CQL
UDT (see
TypeCodec.AbstractUDTCodec.serialize(Object, ProtocolVersion) ). |
abstract ByteBuffer |
TypeCodec.PrimitiveBooleanCodec.serializeNoBoxing(boolean v,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
TypeCodec.PrimitiveByteCodec.serializeNoBoxing(byte v,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
TypeCodec.PrimitiveDoubleCodec.serializeNoBoxing(double v,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
TypeCodec.PrimitiveFloatCodec.serializeNoBoxing(float v,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
TypeCodec.PrimitiveIntCodec.serializeNoBoxing(int v,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
TypeCodec.PrimitiveLongCodec.serializeNoBoxing(long v,
ProtocolVersion protocolVersion) |
abstract ByteBuffer |
TypeCodec.PrimitiveShortCodec.serializeNoBoxing(short v,
ProtocolVersion protocolVersion) |
Cluster.Builder |
Cluster.Builder.withProtocolVersion(ProtocolVersion version)
The native protocol version to use.
|
static void |
CodecUtils.writeSize(ByteBuffer output,
int size,
ProtocolVersion version)
Utility method that writes a size value.
|
static void |
CodecUtils.writeValue(ByteBuffer output,
ByteBuffer value,
ProtocolVersion version)
Utility method that writes a value.
|
Constructor and Description |
---|
AbstractGettableData(ProtocolVersion protocolVersion)
Creates a new AbstractGettableData object.
|
ProtocolOptions(int port,
ProtocolVersion protocolVersion,
int maxSchemaAgreementWaitSeconds,
SSLOptions sslOptions,
AuthProvider authProvider)
Creates a new
ProtocolOptions instance using the provided port and SSL context. |
ProtocolOptions(int port,
ProtocolVersion protocolVersion,
int maxSchemaAgreementWaitSeconds,
SSLOptions sslOptions,
AuthProvider authProvider,
boolean noCompact)
Creates a new
ProtocolOptions instance using the provided port and SSL context. |
ProtocolOptions(int port,
ProtocolVersion protocolVersion,
int maxSchemaAgreementWaitSeconds,
SSLOptions sslOptions,
AuthProvider authProvider,
boolean noCompact,
boolean useAdvancedShardAwarness,
int portLow,
int portHigh)
Creates a new
ProtocolOptions instance using the provided port and SSL context. |
Modifier and Type | Method and Description |
---|---|
ProtocolVersion |
UnsupportedFeatureException.getCurrentVersion() |
ProtocolVersion |
UnsupportedProtocolVersionException.getServerVersion()
The version with which the server replied.
|
ProtocolVersion |
UnsupportedProtocolVersionException.getUnsupportedVersion()
The version with which the client sent its request.
|
Constructor and Description |
---|
UnsupportedFeatureException(ProtocolVersion currentVersion,
String msg) |
UnsupportedProtocolVersionException(EndPoint endPoint,
ProtocolVersion unsupportedVersion,
ProtocolVersion serverVersion) |
UnsupportedProtocolVersionException(EndPoint endPoint,
ProtocolVersion unsupportedVersion,
ProtocolVersion serverVersion,
Throwable cause) |
Modifier and Type | Method and Description |
---|---|
Map<String,ByteBuffer> |
BuiltStatement.getNamedValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
ByteBuffer |
BuiltStatement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
ByteBuffer |
Batch.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the first non-null routing key of the statements in this batch or null otherwise.
|
ByteBuffer[] |
BuiltStatement.getValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
ByteBuffer[] |
Batch.getValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
Modifier and Type | Method and Description |
---|---|
Map<String,ByteBuffer> |
SchemaStatement.getNamedValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
ByteBuffer |
SchemaStatement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the routing key (in binary raw form) to use for token aware routing of this query.
|
ByteBuffer[] |
SchemaStatement.getValues(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
Copyright © 2012–2024. All rights reserved.