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.
|
com.datastax.driver.extras.codecs |
This package and its subpackages contain several convenience
TypeCodec s. |
com.datastax.driver.extras.codecs.arrays |
This package contains a collection of convenience
TypeCodec instances useful for serializing between CQL lists and Java arrays. |
com.datastax.driver.extras.codecs.date |
This package contains a collection of convenience
TypeCodec instances useful for serializing between CQL temporal types and Java primitive types. |
com.datastax.driver.extras.codecs.enums |
This package contains a collection of convenience
TypeCodec instances useful for serializing between CQL types and Java enums. |
com.datastax.driver.extras.codecs.jdk8 |
This package contains a collection of convenience
TypeCodec instances useful for serializing between CQL types and Java 8 types, such as the ones
from the java.time API and java.util.Optional . |
com.datastax.driver.extras.codecs.joda |
This package contains a collection of convenience
TypeCodec instances useful for serializing between CQL types and Joda Time types such as DateTime . |
com.datastax.driver.extras.codecs.json |
This package contains a collection of convenience
TypeCodec
instances useful for serializing JSON structures. |
com.datastax.driver.mapping |
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 |
StatementWrapper.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.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the routing key for the query.
|
ByteBuffer |
BoundStatement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
The routing key for this bound query.
|
ByteBuffer |
BatchStatement.getRoutingKey(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
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 |
StatementWrapper.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
int |
Statement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the number of bytes required to encode this statement.
|
int |
RegularStatement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
int |
BoundStatement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry)
Returns the number of bytes required to encode this statement.
|
int |
BatchStatement.requestSizeInBytes(ProtocolVersion protocolVersion,
CodecRegistry codecRegistry) |
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. |
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) |
Modifier and Type | Method and Description |
---|---|
T |
ParsingCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
O |
MappingCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
ByteBuffer |
MappingCodec.serialize(O value,
ProtocolVersion protocolVersion) |
ByteBuffer |
ParsingCodec.serialize(T value,
ProtocolVersion protocolVersion) |
Modifier and Type | Method and Description |
---|---|
E[] |
ObjectArrayCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
T |
AbstractPrimitiveArrayCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
protected void |
DoubleArrayCodec.deserializeElement(ByteBuffer input,
double[] array,
int index,
ProtocolVersion protocolVersion) |
protected void |
FloatArrayCodec.deserializeElement(ByteBuffer input,
float[] array,
int index,
ProtocolVersion protocolVersion) |
protected void |
IntArrayCodec.deserializeElement(ByteBuffer input,
int[] array,
int index,
ProtocolVersion protocolVersion) |
protected void |
LongArrayCodec.deserializeElement(ByteBuffer input,
long[] array,
int index,
ProtocolVersion protocolVersion) |
protected abstract void |
AbstractPrimitiveArrayCodec.deserializeElement(ByteBuffer input,
T array,
int index,
ProtocolVersion protocolVersion)
Read the
index th element of array from input . |
ByteBuffer |
ObjectArrayCodec.serialize(E[] value,
ProtocolVersion protocolVersion) |
ByteBuffer |
AbstractPrimitiveArrayCodec.serialize(T array,
ProtocolVersion protocolVersion) |
protected void |
DoubleArrayCodec.serializeElement(ByteBuffer output,
double[] array,
int index,
ProtocolVersion protocolVersion) |
protected void |
FloatArrayCodec.serializeElement(ByteBuffer output,
float[] array,
int index,
ProtocolVersion protocolVersion) |
protected void |
IntArrayCodec.serializeElement(ByteBuffer output,
int[] array,
int index,
ProtocolVersion protocolVersion) |
protected void |
LongArrayCodec.serializeElement(ByteBuffer output,
long[] array,
int index,
ProtocolVersion protocolVersion) |
protected abstract void |
AbstractPrimitiveArrayCodec.serializeElement(ByteBuffer output,
T array,
int index,
ProtocolVersion protocolVersion)
Write the
index th element of array to output . |
Modifier and Type | Method and Description |
---|---|
long |
SimpleTimestampCodec.deserializeNoBoxing(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
int |
SimpleDateCodec.deserializeNoBoxing(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
ByteBuffer |
SimpleDateCodec.serializeNoBoxing(int value,
ProtocolVersion protocolVersion) |
ByteBuffer |
SimpleTimestampCodec.serializeNoBoxing(long value,
ProtocolVersion protocolVersion) |
Modifier and Type | Method and Description |
---|---|
E |
EnumOrdinalCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
ByteBuffer |
EnumOrdinalCodec.serialize(E value,
ProtocolVersion protocolVersion) |
Modifier and Type | Method and Description |
---|---|
ZoneId |
ZoneIdCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
LocalTime |
LocalTimeCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
LocalDateTime |
LocalDateTimeCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
LocalDate |
LocalDateCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
Instant |
InstantCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
protected ZonedDateTime |
ZonedDateTimeCodec.deserializeAndSetField(ByteBuffer input,
ZonedDateTime target,
int index,
ProtocolVersion protocolVersion) |
ByteBuffer |
InstantCodec.serialize(Instant value,
ProtocolVersion protocolVersion) |
ByteBuffer |
LocalDateCodec.serialize(LocalDate value,
ProtocolVersion protocolVersion) |
ByteBuffer |
LocalDateTimeCodec.serialize(LocalDateTime value,
ProtocolVersion protocolVersion) |
ByteBuffer |
LocalTimeCodec.serialize(LocalTime value,
ProtocolVersion protocolVersion) |
ByteBuffer |
ZoneIdCodec.serialize(ZoneId value,
ProtocolVersion protocolVersion) |
protected ByteBuffer |
ZonedDateTimeCodec.serializeField(ZonedDateTime source,
int index,
ProtocolVersion protocolVersion) |
Modifier and Type | Method and Description |
---|---|
org.joda.time.LocalTime |
LocalTimeCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
org.joda.time.LocalDate |
LocalDateCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
org.joda.time.Instant |
InstantCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
protected org.joda.time.DateTime |
DateTimeCodec.deserializeAndSetField(ByteBuffer input,
org.joda.time.DateTime target,
int index,
ProtocolVersion protocolVersion) |
ByteBuffer |
InstantCodec.serialize(org.joda.time.Instant value,
ProtocolVersion protocolVersion) |
ByteBuffer |
LocalDateCodec.serialize(org.joda.time.LocalDate value,
ProtocolVersion protocolVersion) |
ByteBuffer |
LocalTimeCodec.serialize(org.joda.time.LocalTime value,
ProtocolVersion protocolVersion) |
protected ByteBuffer |
DateTimeCodec.serializeField(org.joda.time.DateTime source,
int index,
ProtocolVersion protocolVersion) |
Modifier and Type | Method and Description |
---|---|
javax.json.JsonStructure |
Jsr353JsonCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
T |
JacksonJsonCodec.deserialize(ByteBuffer bytes,
ProtocolVersion protocolVersion) |
ByteBuffer |
Jsr353JsonCodec.serialize(javax.json.JsonStructure value,
ProtocolVersion protocolVersion) |
ByteBuffer |
JacksonJsonCodec.serialize(T value,
ProtocolVersion protocolVersion) |
Constructor and Description |
---|
MappingManager(Session session,
MappingConfiguration configuration,
ProtocolVersion protocolVersion)
Creates a new
MappingManager using the provided Session with default MapperConfiguration . |
MappingManager(Session session,
ProtocolVersion protocolVersion)
Creates a new
MappingManager using the provided Session with default MapperConfiguration . |
Copyright © 2012–2019. All rights reserved.