aboutsummaryrefslogtreecommitdiff
path: root/src/fields/Key.ts
diff options
context:
space:
mode:
authorTyler Schicke <tyler_schicke@brown.edu>2019-01-15 22:31:57 -0500
committerTyler Schicke <tyler_schicke@brown.edu>2019-01-15 22:31:57 -0500
commit89204d74d2a5014b4e241973b1bdb8461ed4f78c (patch)
tree4bf58acfdad603375953b2de3610dc946e569b71 /src/fields/Key.ts
parent3de39e2608e62a278b9c8cc37b53333f0877fa59 (diff)
More stuff set up
Diffstat (limited to 'src/fields/Key.ts')
-rw-r--r--src/fields/Key.ts37
1 files changed, 37 insertions, 0 deletions
diff --git a/src/fields/Key.ts b/src/fields/Key.ts
new file mode 100644
index 000000000..42881c8a6
--- /dev/null
+++ b/src/fields/Key.ts
@@ -0,0 +1,37 @@
+import { Field } from "./Field"
+import { Utils } from "../Utils";
+
+export class Key extends Field {
+ get Name():string {
+ return this.name;
+ }
+
+ constructor(private name:string){
+ super(Utils.GenerateDeterministicGuid(name));
+ }
+
+ TrySetValue(value: any): boolean {
+ throw new Error("Method not implemented.");
+ }
+
+ GetValue() {
+ return this.Name;
+ }
+
+ Copy(): Field {
+ return this;
+ }
+
+
+}
+
+export namespace KeyStore {
+ export let Prototype = new Key("Prototype");
+ export let X = new Key("X");
+ export let Y = new Key("Y");
+ export let Width = new Key("Width");
+ export let Height = new Key("Height");
+ export let Data = new Key("Data");
+ export let View = new Key("View");
+ export let ViewProps = new Key("ViewProps");
+} \ No newline at end of file