public class UDTClassInfoImpl.POJOContext extends ClassInfoImpl.POJOContext
POJOContext class provides a specific context for the POJO
as referenced while building an insert or update statement.objectkeyspaceKeys| Constructor and Description |
|---|
POJOContext(T object)
Instantiates a new
POJOContext object. |
| Modifier and Type | Method and Description |
|---|---|
Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>> |
getColumnValue(CharSequence name)
Retrieves the specified column value from the POJO.
|
Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>> |
getColumnValue(String tname,
CharSequence name)
Retrieves the specified column value from the POJO and the specified
table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getColumnValues()
Retrieves all columns and their values from the POJO.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getColumnValues(CharSequence... names)
Retrieves the specified columns and their values from the POJO.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getColumnValues(Iterable<CharSequence> names)
Retrieves the specified columns and their values from the POJO.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getColumnValues(String tname)
Retrieves all columns and their values from the POJO and the specified
table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getColumnValues(String tname,
CharSequence... names)
Retrieves the specified columns and their values from the POJO and the
specified table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getColumnValues(String tname,
Iterable<CharSequence> names)
Retrieves the specified columns and their values from the POJO and the
specified table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getKeyspaceAndPartitionKeyColumnValues(String tname)
Retrieves all keyspace and partition key columns and their values from the
POJO and the specified table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getKeyspaceAndPrimaryKeyColumnValues(String tname)
Retrieves all keyspace and primary key columns and their values from the
POJO and the specified table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getMandatoryAndPrimaryKeyColumnValues(String tname)
Retrieves all mandatory and primary key columns and their values from
the POJO and the specified table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getMandatoryColumnValues()
Retrieves all mandatory columns and their values from the POJO.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getPartitionKeyColumnValues(String tname)
Retrieves all partition key columns and their values from the POJO and the
specified table.
|
Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> |
getPrimaryKeyColumnValues(String tname)
Retrieves all primary key columns and their values from the POJO and the
specified table.
|
protected void |
populateKeyspaceKeys(Map<String,FieldInfoImpl<T>> kkeysFields)
Populates the keyspace keys defined in the given map from the POJO.
|
addKeyspaceKey, getKeyspaceKeyValues, getNonPrimaryKeyColumnValues, getObject, getPrimaryKeyColumnValuesaddKeyspaceKey, getClassInfo, getInitialObjects, getKeyspace, getObject, getObject, getObjectClasspublic POJOContext(T object)
POJOContext object.object - the POJO objectNullPointerException - if object is nullIllegalArgumentException - if object is not of the
appropriate classprotected final void populateKeyspaceKeys(Map<String,FieldInfoImpl<T>> kkeysFields)
populateKeyspaceKeys in class ClassInfoImpl.POJOContextkkeysFields - the map of keyspace key fields from the POJO where to extract
the keyspace key valuesClassInfoImpl.POJOContext.populateKeyspaceKeys(java.util.Map)public Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getColumnValues()
null map of all column/value pairs for the POJOIllegalArgumentException - if a mandatory column is missing from the POJOpublic final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getColumnValues(String tname)
getColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve columnsnull map of all column/value pairs for the POJOClassInfoImpl.POJOContext.getColumnValues(java.lang.String)public final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getPartitionKeyColumnValues(String tname)
getPartitionKeyColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve columnsnull map of all partition key column/value pairs
for the POJOClassInfoImpl.POJOContext.getPartitionKeyColumnValues(java.lang.String)public final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getKeyspaceAndPartitionKeyColumnValues(String tname)
getKeyspaceAndPartitionKeyColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve columnsnull map of all keyspace key and partition key
column/value pairs for the POJOClassInfoImpl.POJOContext.getKeyspaceAndPartitionKeyColumnValues(java.lang.String)public final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getPrimaryKeyColumnValues(String tname)
getPrimaryKeyColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve columnsnull map of all primary key column/value pairs
for the POJOClassInfoImpl.POJOContext.getPrimaryKeyColumnValues(java.lang.String)public final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getKeyspaceAndPrimaryKeyColumnValues(String tname)
getKeyspaceAndPrimaryKeyColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve columnsnull map of all keyspace key and primary key
column/value pairs for the POJOClassInfoImpl.POJOContext.getKeyspaceAndPrimaryKeyColumnValues(java.lang.String)public Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getMandatoryColumnValues()
null map of all mandatory column/value pairs
for the POJOIllegalArgumentException - if a column is missing from the POJOpublic final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getMandatoryAndPrimaryKeyColumnValues(String tname)
getMandatoryAndPrimaryKeyColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve columnsnull map of all mandatory and primary key
column/value pairs for the POJOClassInfoImpl.POJOContext.getMandatoryAndPrimaryKeyColumnValues(java.lang.String)public Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>> getColumnValue(CharSequence name)
name - the name of the column to retrieveIllegalArgumentException - if the column name is not defined by the
POJO or is mandatory and missing from the POJOpublic final Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>> getColumnValue(String tname, CharSequence name)
getColumnValue in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve the columnname - the name of the column to retrieveClassInfoImpl.POJOContext.getColumnValue(java.lang.String, java.lang.CharSequence)public Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getColumnValues(Iterable<CharSequence> names)
names - the names of the columns to retrievenull map of all requested column/value pairs
for the POJOIllegalArgumentException - if any of the column names are not defined
by the POJO or is mandatory and missing from the POJOpublic final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getColumnValues(String tname, Iterable<CharSequence> names)
getColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve the columnnames - the names of the columns to retrievenull map of all requested column/value pairs
for the POJOClassInfoImpl.POJOContext.getColumnValues(java.lang.String, java.lang.Iterable)public Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getColumnValues(CharSequence... names)
names - the names of the columns to retrievenull map of all requested column/value pairs
for the POJOIllegalArgumentException - if any of the column names are not defined
by the POJO or is mandatory and missing from the POJOpublic final Map<String,Triple<Object,CQLDataType,com.datastax.driver.core.TypeCodec<?>>> getColumnValues(String tname, CharSequence... names)
getColumnValues in class ClassInfoImpl.POJOContexttname - the name of the table from which to retrieve the columnnames - the names of the columns to retrievenull map of all requested column/value pairs
for the POJOClassInfoImpl.POJOContext.getColumnValues(java.lang.String, java.lang.CharSequence[])Copyright (C) 2015-2017 The Helenus Driver Project Authors.