diff --git a/src/main/java/de/uniluebeck/mi/projmi6/model/Patient.java b/src/main/java/de/uniluebeck/mi/projmi6/model/Patient.java index 2d9b429..57bbb45 100644 --- a/src/main/java/de/uniluebeck/mi/projmi6/model/Patient.java +++ b/src/main/java/de/uniluebeck/mi/projmi6/model/Patient.java @@ -27,7 +27,6 @@ public class Patient extends Version { private SimpleStringProperty cave = new SimpleStringProperty(this, "cave"); - public int getPatID() { return patID.get(); } @@ -210,6 +209,18 @@ public class Patient extends Version { this.geschlecht = geschlecht; } + public static Geschlecht parseChar(final char id) { + switch (id) { + case 'm': + return MALE; + case 'w': + return FEMALE; + case 'o': + default: + return OTHER; + } + + } @Override public String toString() { @@ -237,4 +248,4 @@ public class Patient extends Version { return familienstand; } } -} +} \ No newline at end of file