diff options
author | Tyler Schicke <tyler_schicke@brown.edu> | 2019-02-22 03:01:30 -0500 |
---|---|---|
committer | Tyler Schicke <tyler_schicke@brown.edu> | 2019-02-22 03:01:30 -0500 |
commit | fed460a9dffd85b32e30aeb112f2c7c47371bce6 (patch) | |
tree | 16f8c1d9b4a5e3e4e1b22e6b6520b793801c8b28 /src/fields/Document.ts | |
parent | 3f9e4363e6601eac175ff71192d414fd6051d921 (diff) |
Added CollectionView
Switched sub-collections to not inherit from CollectionViewBase
Diffstat (limited to 'src/fields/Document.ts')
-rw-r--r-- | src/fields/Document.ts | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/fields/Document.ts b/src/fields/Document.ts index 6667485b6..ff13732b3 100644 --- a/src/fields/Document.ts +++ b/src/fields/Document.ts @@ -90,6 +90,15 @@ export class Document extends Field { return field; } + GetAsync(key: Key, callback: (field: Field) => void): boolean { + //This currently doesn't deal with prototypes + if (this._proxies.has(key.Id)) { + Server.GetDocumentField(this, key, callback); + return true; + } + return false; + } + GetT<T extends Field = Field>(key: Key, ctor: { new(...args: any[]): T }, ignoreProto: boolean = false): FieldValue<T> { var getfield = this.Get(key, ignoreProto); if (getfield != FieldWaiting) { |