@Documented @Target(value=FIELD) @Retention(value=RUNTIME) public @interface Column
SpannerPersistentProperty
that allows specifying the column name
instead of deriving it from the field's name.Modifier and Type | Optional Element and Description |
---|---|
String |
name
The custom name of the column in the Spanner table, which can differ from the name of the
field which it annotates.
|
boolean |
nullable
If the column's schema should be NOT NULL when generating a schema based on an
entity class.
|
boolean |
spannerCommitTimestamp
This setting takes effect when the entity in which it appears is used to generate
schema DDL.
|
TypeCode |
spannerType
Optionally directly specify the column type in Cloud Spanner.
|
long |
spannerTypeMaxLength
The maximum length of the column in Cloud Spanner terms.
|
public abstract String name
public abstract long spannerTypeMaxLength
public abstract boolean nullable
false
if the column should be NOT NULL in generated DDL.
true
otherwise.public abstract TypeCode spannerType
public abstract boolean spannerCommitTimestamp
true
, then the column corresponding to the annotated property
will be auto-populated with the latest Cloud Spanner TrueTime commit timestamp of the
row. false
for all other usage and columns.true
for auto-populating commit timestamp. false
otherwise.Copyright © 2020 Pivotal Software, Inc.. All rights reserved.