deno.land / x / pg_mem@2.8.1 / schema / view.ts

نووسراو ببینە
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import { QueryError, Reg, _Explainer, _ISchema, _ISelection, _IView, _Transaction } from '../interfaces-private.ts';import { DataSourceBase, FilterBase } from '../transforms/transform-base.ts';
export class View extends FilterBase<any> implements _IView { get type(): 'view' { return 'view'; }
private _reg?: Reg; get reg(): Reg { if (!this._reg) { throw new QueryError(`relation "${this.name}" does not exist`); } return this._reg; }
constructor(readonly ownerSchema: _ISchema, readonly name: string, readonly selection: _ISelection) { super(selection); }

enumerate(t: _Transaction): Iterable<any> { return this.selection.enumerate(t); }
hasItem(value: any, t: _Transaction): boolean { return this.selection.hasItem(value, t); }
explain(e: _Explainer) { return this.selection.explain(e); }
stats(t: _Transaction) { return this.selection.stats(t); }

register() { // once fields registered, // then register the table // (column registrations need it not to be registered yet) this._reg = this.ownerSchema._reg_register(this); return this; }
drop(t: _Transaction): void { throw new Error('Method not implemented.'); }}
pg_mem

Version Info

Tagged at
4 months ago