@Target(value={FIELD,METHOD}) @Retention(value=RUNTIME) public @interface Column
Note that this annotation is generally optional in the sense that any field or any getter
method of a Java bean property of a class annotated by Table
will be mapped by default to
a column having the same name than this field / property, unless that field or method has the
Transient
annotation. As such, this annotation is mainly useful when the CQL column name
does not correspond to the field or property name itself.
Modifier and Type | Optional Element and Description |
---|---|
boolean |
caseSensitive
Whether the value return by
name() is case-sensitive (this has no effect if no name is
provided in the annotation). |
Class<? extends TypeCodec<?>> |
codec
A custom codec that will be used to serialize and deserialize the column.
|
String |
name
Name of the column being mapped in Cassandra.
|
public abstract String name
NamingStrategy
of the current MappingConfiguration
.""
to use the naming strategy.public abstract boolean caseSensitive
name()
is case-sensitive (this has no effect if no name is
provided in the annotation).public abstract Class<? extends TypeCodec<?>> codec
Copyright © 2012–2018. All rights reserved.