@codification/cutwater-aws
Version:
A library providing general functionality for TypeScript based AWS projects.
37 lines • 1.45 kB
TypeScript
import { AttributeMap } from './AttributeMap';
declare enum ValueType {
S = "S",
N = "N",
B = "B",
SS = "SS",
NS = "NS",
BS = "BS",
M = "M",
L = "L",
NULL = "NULL",
BOOL = "BOOL"
}
export declare class DynamoItem {
item: AttributeMap;
constructor(item?: AttributeMap);
prune(): AttributeMap;
toSafeString(key: string): string;
toString(key: string, defaultValue?: string): string | undefined;
setString(key: string, value?: string): void;
setStringParts(key: string, ...values: Array<string | number | undefined>): void;
toStringSet(key: string, defaultValue?: string[]): string[];
setStringSet(key: string, value?: string[]): void;
toSafeNumber(key: string): number;
toNumber(key: string, defaultValue?: number): number | undefined;
setNumber(key: string, value?: number): void;
toBoolean(key: string, defaultValue?: boolean): boolean;
setBoolean(key: string, value?: boolean): void;
toObject<T>(key: string, defaultValue?: T): T | undefined;
setObject<T>(key: string, value: T): void;
toStringPart(key: string, index: number, defaultValue?: string): string | undefined;
toNumberPart(key: string, index: number, defaultValue?: number): number | undefined;
protected getValue<T>(key: string, type: ValueType): T | undefined;
protected isEmtptyAttribute(key: string): boolean;
}
export {};
//# sourceMappingURL=DynamoItem.d.ts.map