public final class ResolvedStaticAttribute<T> extends Object
Modifier and Type | Method and Description |
---|---|
Function<T,AttributeValue> |
attributeGetterMethod() |
String |
attributeName() |
static <T,R> ResolvedStaticAttribute<T> |
create(StaticAttribute<T,R> staticAttribute,
AttributeType<R> attributeType) |
StaticTableMetadata |
tableMetadata() |
<R> ResolvedStaticAttribute<R> |
transform(Function<R,T> transform,
Consumer<R> createComponent)
Return a transformed copy of this attribute that knows how to get/set from a different type of object given a
function that can convert the containing object itself.
|
BiConsumer<T,AttributeValue> |
updateItemMethod() |
public static <T,R> ResolvedStaticAttribute<T> create(StaticAttribute<T,R> staticAttribute, AttributeType<R> attributeType)
public <R> ResolvedStaticAttribute<R> transform(Function<R,T> transform, Consumer<R> createComponent)
R
- The type being transformed to.transform
- A function that converts the object storing the attribute from the source type to the
destination type.createComponent
- A consumer to create a new instance of the component object when required. A null value
will bypass this logic.public String attributeName()
public Function<T,AttributeValue> attributeGetterMethod()
public BiConsumer<T,AttributeValue> updateItemMethod()
public StaticTableMetadata tableMetadata()
Copyright © 2020. All rights reserved.