Module

x/pg_mem/interfaces-private.ts>_ISchema

An in memory postgres DB instance for your unit tests
Go to Latest
interface _ISchema
implements ISchema
import { type _ISchema } from "https://dotland.deno.dev/x/pg_mem@2.6.3/interfaces-private.ts";

Properties

readonly
name: string
readonly
db: _IDb
readonly
dualTable: _ITable

Methods

getThisOrSiblingFor(name: QName): _ISchema

If the given name refers to another schema, then get it. Else, get this

executeCreateExtension(p: CreateExtensionStatement): void
dropFunction(fn: DropFunctionStatement): void
explainSelect(sql: string): _SelectExplanation
explainLastSelect(): _SelectExplanation | undefined
getTable(table: string): _ITable
getTable(table: string, nullIfNotFound?: boolean): _ITable
tablesCount(t: _Transaction): number
listTables(t: _Transaction): Iterable<_ITable>
declareTable(table: Schema, noSchemaChange?: boolean): _ITable
createSequence(): _ISequence
resolveFunction(
name: string | QName,
args: IValue[],
forceOwn?: boolean,
): _FunctionDefinition | nil

Get functions matching this overload

getFunction(name: string, args: _IType[]): _FunctionDefinition | nil

Get an exact function def from its signature (do not use that to resolve overload)

resolveOperator(
left: IValue,
right: IValue,
forceOwn?: boolean,
): _OperatorDefinition | nil

Get operator matching this overload

getObject(p: QName): _IRelation
getObject(p: QName, opts: BeingCreated): _IRelation
getObject(p: QName, opts?: QueryObjOpts): _IRelation | null
getOwnObject(name: string): _IRelation | null
parseType(t: string): _IType
getType(t: TypeQuery): _IType
getType(_t: TypeQuery, opts?: QueryObjOpts): _IType | null
getOwnType(name: DataTypeDef): _IType | null
getObjectByRegClassId(reg: number): _IRelation
getObjectByRegClassId(reg: number, opts?: QueryObjOpts): _IRelation | null
getOwnObjectByRegClassId(reg: number): _IRelation | null
getObjectByRegOrName(reg: RegClass): _IRelation
getObjectByRegOrName(reg: RegClass, opts?: QueryObjOpts): _IRelation | null
setReadonly(): void
_registerTypeSizeable(name: string, type: (sz?: number) => _IType): this
_registerType(type: _IType): this
_unregisterType(type: _IType): this
_reg_register(rel: _IRelation): Reg
_reg_unregister(rel: _IRelation): void
_reg_rename(
oldName: string,
newName: string,
): void