summaryrefslogtreecommitdiffstats
path: root/src/de/fhswf/in/inf/se/notepadMinusMinus/model/Grade.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/de/fhswf/in/inf/se/notepadMinusMinus/model/Grade.java')
-rw-r--r--src/de/fhswf/in/inf/se/notepadMinusMinus/model/Grade.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/de/fhswf/in/inf/se/notepadMinusMinus/model/Grade.java b/src/de/fhswf/in/inf/se/notepadMinusMinus/model/Grade.java
index 9c674d6..ad03065 100644
--- a/src/de/fhswf/in/inf/se/notepadMinusMinus/model/Grade.java
+++ b/src/de/fhswf/in/inf/se/notepadMinusMinus/model/Grade.java
@@ -9,6 +9,7 @@ import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlValue;
+import javafx.beans.Observable;
import javafx.beans.property.IntegerProperty;
import javafx.beans.property.ObjectProperty;
import javafx.beans.property.SimpleIntegerProperty;
@@ -17,6 +18,7 @@ import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.StringProperty;
import javafx.collections.FXCollections;
import javafx.collections.ObservableList;
+import javafx.util.Callback;
/**
* TODO Add comment here
@@ -41,6 +43,13 @@ public class Grade
private IntegerProperty attempt = new SimpleIntegerProperty(1);
+ public static Callback<Grade, Observable[]> extractor()
+ {
+ return (Grade grade) -> new Observable[] { grade.semesterProperty(),
+ grade.modulenameProperty(), grade.ectsProperty(),
+ grade.gradeProperty(), grade.attemptProperty() };
+ }
+
public final IntegerProperty semesterProperty()
{
return this.semester;