UNPKG

@bitblit/ratchet-aws

Version:

Common tools for use with AWS browser and node

16 lines (15 loc) 694 B
import { SimpleDaoItem } from './simple-dao-item.js'; import { S3CacheRatchetLike } from '../s3/s3-cache-ratchet-like.js'; export declare class S3SimpleDao<T extends SimpleDaoItem> { private cache; private prefix?; constructor(cache: S3CacheRatchetLike, prefix?: string); buildPathPrefix(path: string): string; buildFullPath(id: string, path?: string): string; exists(id: string, path?: string): Promise<boolean>; fetch(id: string, path?: string): Promise<T>; store(item: T, path?: string): Promise<T>; listItems(path?: string): Promise<string[]>; fetchItemsInPath(path?: string): Promise<T[]>; delete(id: string, path?: string): Promise<boolean>; }