dynamodb-toolbox
Version:
Lightweight and type-safe query builder for DynamoDB and TypeScript.
21 lines (20 loc) • 1.31 kB
TypeScript
import type { UpdateItemInput } from '../../../entity/actions/update/index.js';
import type { Entity } from '../../../entity/index.js';
import type { Require } from '../../../types/require.js';
import type { TransactWriteItem, WriteTransactionImplementation } from '../transactWrite/transaction.js';
import { WriteTransaction } from '../transactWrite/transaction.js';
import { $item, $options } from './constants.js';
import type { UpdateTransactionOptions } from './options.js';
export declare class UpdateTransaction<ENTITY extends Entity = Entity, OPTIONS extends UpdateTransactionOptions<ENTITY> = UpdateTransactionOptions<ENTITY>> extends WriteTransaction<ENTITY> implements WriteTransactionImplementation<ENTITY> {
static actionName: "transactUpdate";
[$item]?: UpdateItemInput<ENTITY>;
[$options]: OPTIONS;
constructor(entity: ENTITY, item?: UpdateItemInput<ENTITY>, options?: OPTIONS);
item(nextItem: UpdateItemInput<ENTITY>): UpdateTransaction<ENTITY>;
options<NEXT_OPTIONS extends UpdateTransactionOptions<ENTITY>>(nextOptions: NEXT_OPTIONS | ((prevOptions: OPTIONS) => NEXT_OPTIONS)): UpdateTransaction<ENTITY, NEXT_OPTIONS>;
params(): Require<TransactWriteItem, 'Update'> & {
ToolboxItem: UpdateItemInput<ENTITY, {
filled: true;
}>;
};
}