* Add area granulometry (not used for the moment)
[master-thesis.git] / Parasitemia / Parasitemia / GUI / State.fs
diff --git a/Parasitemia/Parasitemia/GUI/State.fs b/Parasitemia/Parasitemia/GUI/State.fs
new file mode 100644 (file)
index 0000000..a4a1773
--- /dev/null
@@ -0,0 +1,17 @@
+module State
+
+open System.Collections.Generic
+
+type State () =
+    let cells = List<Types.Cell>()
+
+    member val FilePath: string = "" with get, set
+    member val PatientID: string = "" with get, set
+
+    member this.Save () =
+        let data = { Pia.sources = []; Pia.patientID = this.PatientID }
+        Pia.save this.FilePath data
+
+    member this.Load () =
+        let data = Pia.load this.FilePath
+        this.PatientID <- data.patientID
\ No newline at end of file