blob: 461e247dba28819a6c75d38f089741dc12869e6f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
import { Copy, OnUpdate, Parent, ToScriptString, ToString } from "./FieldSymbols";
import { RefField } from "./RefField";
export abstract class ObjectField {
public [OnUpdate]?: (diff?: any) => void;
public [Parent]?: RefField | ObjectField;
abstract [Copy](): ObjectField;
abstract [ToScriptString](): string;
abstract [ToString](): string;
}
export namespace ObjectField {
export function MakeCopy<T extends ObjectField>(field: T) {
return field?.[Copy]();
}
}
|