Skip to content

Commit

Permalink
DOC
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael O'Brien committed Sep 6, 2023
1 parent 25786cd commit 334a726
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/Table.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {
Paged,
Entity,
} from './Model'
import { Metrics } from './Metrics'
import {Metrics} from './Metrics'
import {DynamoDBRecord} from 'aws-lambda'

export type EntityGroup = {
Expand Down Expand Up @@ -102,6 +102,11 @@ export class Table<Schema extends OneSchema = any> {
name: T extends ModelNames<Schema> ? T : ModelNames<Schema>,
options?: {nothrow?: boolean}
): T extends string ? Model<Entity<Schema['models'][T]>> : Model<Entity<ExtractModel<T>>>

/* Proposed
getModel<T extends ModelNames<Schema>>(name: T, options?: {nothrow?: boolean}): Model<Entity<Schema['models'][T]>>
*/

getCurrentSchema(): {}
groupByType(items: AnyEntity[], params?: OneParams): EntityGroup
listModels(): AnyModel[]
Expand Down

0 comments on commit 334a726

Please sign in to comment.