A collection of primitive values.

Functions

CassCollection *

cass_collection_new

( type, item_count )

Creates a new collection.

Parameters:
Name Type Details
in type
in item_count

The approximate number of items in the collection.

Returns:
Type Details
CassCollection *

Returns a collection that must be freed.

See Also:
void

cass_collection_free

( collection )

Frees a collection instance.

Parameters:
Name Type Details
in collection
CassError

cass_collection_append_int32

( collection, value )

Appends an “int” to the collection.

Parameters:
Name Type Details
in collection
in value
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_int64

( collection, value )

Appends a “bigint”, “counter” or “timestamp” to the collection.

Parameters:
Name Type Details
in collection
in value
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_float

( collection, value )

Appends a “float” to the collection.

Parameters:
Name Type Details
in collection
in value
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_double

( collection, value )

Appends a “double” to the collection.

Parameters:
Name Type Details
in collection
in value
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_bool

( collection, value )

Appends a “boolean” to the collection.

Parameters:
Name Type Details
in collection
in value
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_string

( collection, value )

Appends a “ascii”, “text” or “varchar” to the collection.

Parameters:
Name Type Details
in collection
in value

The value is copied into the collection object; the memory pointed to by this parameter can be freed after this call.

Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_string_n

( collection, value, value_length )

Same as CassCollection::cass_collection_append_string, but with lengths for string parameters.

Parameters:
Name Type Details
in collection
in value
in value_length
Returns:
Type Details
CassError

same as CassCollection::cass_collection_append_string

See Also:
CassError

cass_collection_append_bytes

( collection, value, value_size )

Appends a “blob” or “varint” to the collection.

Parameters:
Name Type Details
in collection
in value

The value is copied into the collection object; the memory pointed to by this parameter can be freed after this call.

in value_size
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_uuid

( collection, value )

Appends a “uuid” or “timeuuid” to the collection.

Parameters:
Name Type Details
in collection
in value
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_inet

( collection, value )

Appends an “inet” to the collection.

Parameters:
Name Type Details
in collection
in value
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.

CassError

cass_collection_append_decimal

( collection, varint, varint_size, scale )

Appends a “decimal” to the collection.

Parameters:
Name Type Details
in collection
in varint

The value is copied into the collection object; the memory pointed to by this parameter can be freed after this call.

in varint_size
in scale
Returns:
Type Details
CassError

CASS_OK if successful, otherwise an error occurred.