]> WPIA git - gigi.git/blobdiff - src/org/cacert/gigi/dbObjects/Assurance.java
Merge commit '0176ca7cda25ad88e9faa116ffa139ca926de273' into HEAD
[gigi.git] / src / org / cacert / gigi / dbObjects / Assurance.java
index 2d7c593489519aa8c88d92f4c4d5ec504384f034..65a5a59945e98deb1a0f42a57bf322540eb6825d 100644 (file)
@@ -1,11 +1,12 @@
 package org.cacert.gigi.dbObjects;
 
-import org.cacert.gigi.database.GigiResultSet;
+import org.cacert.gigi.dbObjects.wrappers.DataContainer;
 
+@DataContainer
 public class Assurance {
 
     public enum AssuranceType {
-        FACE_TO_FACE("Face to Face Meeting"), TOPUP("TOPUP"), TTP_ASSISTED("TTP-Assisted");
+        FACE_TO_FACE("Face to Face Meeting"), TOPUP("TOPUP"), TTP_ASSISTED("TTP-Assisted"), NUCLEUS("Nucleus Bonus");
 
         private final String description;
 
@@ -32,15 +33,15 @@ public class Assurance {
 
     private String date;
 
-    public Assurance(GigiResultSet res) {
-        super();
-        this.id = res.getInt("id");
-        this.from = User.getById(res.getInt("from"));
-        this.to = User.getById(res.getInt("to"));
-        this.location = res.getString("location");
-        this.method = res.getString("method");
-        this.points = res.getInt("points");
-        this.date = res.getString("date");
+    public Assurance(int id, User from, User to, String location, String method, int points, String date) {
+        this.id = id;
+        this.from = from;
+        this.to = to;
+        this.location = location;
+        this.method = method;
+        this.points = points;
+        this.date = date;
+
     }
 
     public User getFrom() {