A Mapper is responsible to define how a specific type is mapped to an attribute value which can be stored in dynamodb and how to parse the value from dynamodb back into the specific type

### Type parameters

- #### T

### Hierarchy

- MapperForType

### Implemented by

- BooleanMapper
- CollectionMapper
- DateMapper
- EnumMapper
- MomentMapper
- NullMapper
- NumberMapper
- ObjectMapper
- StringMapper

## Index

### Methods

- fromDb
- toDb

## Methods

### fromDb

- fromDb(attributeValue: AttributeValue, propertyMetadata?: PropertyMetadata<T>): T

- - Defined in mapper/for-type/base.mapper.ts:12

  Maps an attribute value coming from dynamodb to an javascript type

  #### Parameters

  - ##### attributeValue: AttributeValue

  - ##### Optional propertyMetadata: PropertyMetadata<T>

  #### Returns T

### toDb

- toDb(propertyValue: T, propertyMetadata?: PropertyMetadata<T>): AttributeValue | null

- - Defined in mapper/for-type/base.mapper.ts:27

  Maps a js value to an attribute value so it can be stored in dynamodb, supported types are

  S(tring) N(umber) B(inary) BOOL NULL S(tring)S(et) N(umber)S(et) B(inary)S(et) L(ist)

  #### Parameters

  - ##### propertyValue: T

  - ##### Optional propertyMetadata: PropertyMetadata<T>

  #### Returns AttributeValue | null

Generated using TypeDoc