static final class DynamoDBMappingsRegistry.Mapping
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private DynamoDBAnnotationRegistry.AnnotationMap |
annotations |
private java.lang.String |
attributeName |
private DynamoDBAutoGeneratorRegistry.Generator<java.lang.Object> |
generator |
private DynamoDBMappingsRegistry.Mappings |
mappings |
private DynamoDBReflectionRegistry.BeanProperty |
property |
Modifier | Constructor and Description |
---|---|
private |
Mapping(DynamoDBMappingsRegistry.Mappings mappings,
DynamoDBReflectionRegistry.BeanProperty property,
DynamoDBAnnotationRegistry.AnnotationMap annotations,
DynamoDBAutoGeneratorRegistry.Generator<java.lang.Object> generator,
java.lang.String attributeName)
Constructs an object attribute mapping for the specified method.
|
Modifier and Type | Method and Description |
---|---|
(package private) java.lang.Object |
autoGenerate(java.lang.Object value)
Auto-genertes the value given the current value.
|
(package private) boolean |
canAutoGenerate(java.lang.Object value,
java.lang.Object objectValue,
DynamoDBMapperConfig.SaveBehavior saveBehavior)
Determines if the mapping value can be auto-generated.
|
(package private) java.lang.String |
getAttributeName()
Gets the attribute name.
|
(package private) DynamoDBAutoGenerateStrategy |
getAutoGenerateStrategy()
Determines if this attribute maps to an auto-generate strategy.
|
private DynamoDBAutoGeneratorRegistry.Generator<java.lang.Object> |
getAutoGenerator()
Gets the auto-generator for this attribute.
|
(package private) ArgumentMarshaller |
getCustomMarshaller()
Gets the custom marshaller.
|
(package private) ArgumentUnmarshaller |
getCustomUnmarshaller()
Gets the custom unmarshaller.
|
(package private) java.util.Collection<java.lang.String> |
getGlobalSecondaryIndexNamesOfIndexHashKey()
Gets the global secondary index names if applicable.
|
(package private) java.util.Collection<java.lang.String> |
getGlobalSecondaryIndexNamesOfIndexRangeKey()
Gets the global secondary index names if applicable.
|
(package private) java.util.Collection<java.lang.String> |
getLocalSecondaryIndexNamesOfIndexRangeKey()
Gets the local secondary index names if applicable.
|
(package private) java.lang.reflect.Method |
getter()
Gets the getter method for this attribute.
|
(package private) java.lang.Object |
getValueOf(java.lang.Object target)
Tries to get the attribute value from the object.
|
(package private) boolean |
isAutoGeneratedKey()
Determines if this attribute maps to an auto-generated key.
|
(package private) boolean |
isAutoGeneratedTimestamp()
Determines if this attribute maps to an auto-generated timestamp.
|
(package private) boolean |
isHashKey()
Determines if this attribute maps to a hash key.
|
(package private) boolean |
isIndexHashKey()
Determines if this attribute maps to an index hash key.
|
(package private) boolean |
isIndexRangeKey()
Determines if this attribute maps to an index range key.
|
(package private) boolean |
isPrimaryKey() |
(package private) boolean |
isRangeKey()
Determines if this attribute maps to a range key.
|
(package private) boolean |
isVersion()
Determines if this attribute maps to a version attribute.
|
(package private) java.lang.reflect.Method |
setter()
Gets the setter method for this attribute.
|
(package private) void |
setValueOf(java.lang.Object target,
java.lang.Object value)
Tries to set the attribute value on the object.
|
private final DynamoDBMappingsRegistry.Mappings mappings
private final DynamoDBReflectionRegistry.BeanProperty property
private final DynamoDBAnnotationRegistry.AnnotationMap annotations
private final DynamoDBAutoGeneratorRegistry.Generator<java.lang.Object> generator
private final java.lang.String attributeName
private Mapping(DynamoDBMappingsRegistry.Mappings mappings, DynamoDBReflectionRegistry.BeanProperty property, DynamoDBAnnotationRegistry.AnnotationMap annotations, DynamoDBAutoGeneratorRegistry.Generator<java.lang.Object> generator, java.lang.String attributeName)
mappings
- The parent mappings reference.property
- The reflection property.annotations
- The annotations.generator
- The generator.attributeName
- The attribute name.private final DynamoDBAutoGeneratorRegistry.Generator<java.lang.Object> getAutoGenerator()
final java.lang.reflect.Method getter()
final java.lang.reflect.Method setter()
final java.lang.Object getValueOf(java.lang.Object target)
target
- The target object.final void setValueOf(java.lang.Object target, java.lang.Object value)
target
- The target object.value
- The value.final boolean isPrimaryKey()
final boolean isAutoGeneratedKey()
final boolean isAutoGeneratedTimestamp()
final boolean isHashKey()
final boolean isIndexHashKey()
final boolean isIndexRangeKey()
final boolean isRangeKey()
final boolean isVersion()
final java.lang.String getAttributeName()
final java.util.Collection<java.lang.String> getGlobalSecondaryIndexNamesOfIndexHashKey()
final java.util.Collection<java.lang.String> getGlobalSecondaryIndexNamesOfIndexRangeKey()
final java.util.Collection<java.lang.String> getLocalSecondaryIndexNamesOfIndexRangeKey()
final DynamoDBAutoGenerateStrategy getAutoGenerateStrategy()
final ArgumentMarshaller getCustomMarshaller()
final ArgumentUnmarshaller getCustomUnmarshaller()
final boolean canAutoGenerate(java.lang.Object value, java.lang.Object objectValue, DynamoDBMapperConfig.SaveBehavior saveBehavior)
value
- The current mapped value.objectValue
- The object instance.saveBehaviour
- The save behaviour.final java.lang.Object autoGenerate(java.lang.Object value)
value
- The current value.