Add Java Date for timestamps

This commit is contained in:
Jeremy Lakeman
2017-03-29 12:46:10 +10:30
parent f060e4dc59
commit fb2322d45f
2 changed files with 8 additions and 0 deletions

View File

@ -1,5 +1,7 @@
package org.servalproject.servaldna.meshmb;
import java.util.Date;
/**
* Created by jeremy on 10/10/16.
*/
@ -9,6 +11,7 @@ public class PlyMessage implements Comparable<PlyMessage>{
public final long offset;
public final String token;
public final long timestamp;
public final Date date;
public final String text;
public PlyMessage(long _row, long offset, String token, long timestamp, String text){
@ -16,6 +19,7 @@ public class PlyMessage implements Comparable<PlyMessage>{
this.offset = offset;
this.token = token;
this.timestamp = timestamp;
this.date = new Date(timestamp * 1000);
this.text = text;
}