Initialize the Table's name, attributes, keySchema and index properties.
Definition of the attribute types required for table and index primary key and for index projected attributes. These need to be defined at the table level since the attributes are table wide concept.
Schema map for the Table's primary key, in the form of { <partition key name>: { keyType: 'HASH' } }.
Name of the DynamoDB table, used to set the TableName when calling DynamoDB methods.
Determines how errors should be handled. The default is to throw on any errors.
Gets the DocumentClient associated with this Table, which may mean creating one.
The DocumentClient used for all Table operations.
Create a binary set from a binary array.
Binary array to create set from.
Options to pass DocumentClient createSet.
Create a number set from a number array.
Number array to create set from.
Options to pass DocumentClient createSet.
Wrapper around the DocumentClient.createSet used by the below create*Set methods to create type safe sets. Choose to leverage DocumentClient implementation of set to allow DocumentClient to correctly auto convert to DynamoDB's native types.
Array of items to create the set from.
Options to pass DocumentClient createSet.
Create a string set from a string array.
String array to create set from.
Options to pass DocumentClient createSet.
Wrapper method for DocumentClient.delete method.
Primary key of item to delete.
Additional optional options to use for delete.
Async promise returned by DocumentClient.delete method.
Creates the params that can be used when calling DocumentClient.delete.
Primary key of the item to delete.
Additional optional options to use for delete.
Input params for DocumentClient.delete.
Wrapper method for DocumentClient.get method.
Primary key of item to get.
Additional optional options to use for get.
Async promise returned by DocumentClient.get method.
Creates the params that can be used when calling DocumentClient.get.
Primary key of the item to get.
Additional optional options to use for get.
Input params for DocumentClient.get.
Gets the partition key name for the Table.
The name of the primary (or HASH) key attribute.
Get the condition that is needed to support a specific PutWriteOptions.
Type of put to get the condition for.
Condition resolver that maps to the PutWriteOptions.
Gets the sort key name for the Table.
The name of the sort (or RANGE) key attribute.
Wrapper method for DocumentClient.put method.
Primary key of item to put.
Additional optional options to use for put.
Async promise returned by DocumentClient.put method.
Creates the params that can be used when calling DocumentClient.put.
Primary key of item to put.
Attributes of the item to put.
Additional optional options to use for put.
Input params for DocumentClient.put.
Wrapper around DocumentClient.query. method that uses the index and table properties with the key and options params.
Primary key with optional KeyCondition to query the secondary index with.
Used in building the query params.
Promise with the query results, including items fetched.
Creates the params that can be used when calling DocumentClient.query method.
Primary key with optional KeyCondition to query the table with.
Used in building the query params.
Input params for DocumentClient.query.
Wrapper around DocumentClient.scan. method that uses the index and table properties with the options param.
Used in building the scan params.
Promise with the scan results, including items fetched.
Creates the params that can be used when calling DocumentClient.scan method.
Used in building the scan params.
Input params for DocumentClient.scan method.
Creates the params that can be used when calling DocumentClient.batchGet method.
Batch get object to set the table get on.
Keys of items to get.
Set of get options for table.
BatchGet object passed in, to support calling execute on same line.
Creates the params that can be used when calling DocumentClient.batchWrite method.
Batch write object to set the table write on.
Items to put in the table.
Keys of items to delete from the table.
BatchWrite object passed in, to support calling execute on same line.
Creates the params that can be used when calling DocumentClient.transactGet method.
Keys of items and associated attributes to get.
TransactGet object passed in, to support calling execute on same line.
Creates the params that can be used when calling DocumentClient.transactWrite method.
Set of operations to write in the transaction.
TransactWrite object passed in, to support calling execute on same line.
Wrapper method for DocumentClient.update method.
Primary key of item to update.
Attributes of the item to update.
Additional optional options to use for update.
Async promise returned by DocumentClient.update method.
Creates the params that can be used when calling DocumentClient.update.
By default this method uses ReturnValues: 'ALL_NEW'
to return all of the properties for an item,
since many APIs or server code use the updated values in some way.
Primary key of item to update.
Attributes of the item to update.
Additional optional options to use for update.
Input params for DocumentClient.update.
Translates options into batch or transact based input params.
Common batch or transact options to set on params.
Input params to set based on options.
Appends attributes names to the ProjectionExpression for input params.
Params to add ProjectionExpression on.
Definition of the attribute types required for table and index primary key and for index projected attributes.
List of attribute names to return.
Params that have ProjectionExpression added to.
Add expressions properties to the params object.
The params object to add expression properties to.
Options used to build params.
Params object that was passed in with expression added.
Add expressions properties to the params object.
The params object to add expression properties to.
Transact write item used to build params.
Params object that was passed in with expression added.
Finds the partition or sort key name for a table or index key schema.
Table key schema to find the primary key in.
Primary key type to look for, either HASH or RANGE.
Name of the key if it exists otherwise an empty string.
Maps PutWriteOptions to one of the put based ItemActions used by Fields to tell the type of put operation.
Put write option to map into a put item action.
Checks if item action is a put based action.
Item actions to check if put.
True if item action is a put action.
Generated using TypeDoc
Object that represents the DynamoDB table.
In most single table designs secondary indexes will be used like in the following example:
examples/Table.ts (imports: examples/Index.ts)