Added README.txt and GPL Header to Source Files
[DHBWCampusApp.git] / app / src / main / java / de / dhbwloe / campusapp / database / NfcCardData.java
index 08a6e2d825ecba61b3e8cc2547a360493ae69fb2..255244690268e9fff4c92ca414355c23cc33474f 100644 (file)
@@ -1,3 +1,18 @@
+/* NfcCardData.java
+ * 
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
 package de.dhbwloe.campusapp.database;
 
 import java.util.Date;
@@ -8,22 +23,12 @@ import java.util.Date;
 public class NfcCardData {
     private int iUniqueId;
     private long iLastUpdate;
-    private String sCardData;
     private int iBalance;
     private int iLastTransaction;
 
-    public NfcCardData(de.dhbwloe.campusapp.nfcreader.cardreader.NfcCardData carddata) {
-        iUniqueId = carddata.getUniqueid();
-        iLastUpdate = (new Date()).getTime()/1000;
-        sCardData = carddata.getCompactCardDataSummary();
-        iBalance = (int)(carddata.getBalanceData() * 100);
-        iLastTransaction = (int)(carddata.getLastTransaction() * 100);
-    }
-
-    public NfcCardData(int uid, long lastupdate, String carddata, int balance, int transaction) {
+    public NfcCardData(int uid, long lastupdate, int balance, int transaction) {
         iUniqueId = uid;
         iLastUpdate = lastupdate;
-        sCardData = carddata;
         iBalance = balance;
         iLastTransaction = transaction;
     }
@@ -32,10 +37,6 @@ public class NfcCardData {
         return iUniqueId;
     }
 
-    public String getCardData() {
-        return sCardData;
-    }
-
     public long getLastUpdate() {
         return iLastUpdate;
     }