public class ActivityRecord extends Object implements Comparable<ActivityRecord>
Modifier and Type | Field and Description |
---|---|
protected int |
batteryLevel |
protected hirondelle.date4j.DateTime |
dateTime |
static int |
INVALID |
protected static TimeZone |
localTimeZone |
protected static TimeZone |
utcTimeZone |
Constructor and Description |
---|
ActivityRecord()
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(ActivityRecord other) |
void |
dumpRecordCsv(Writer writer)
Dump all the record fields of this record
|
void |
dumpRecordCsvHeader(Writer writer)
Dump the header containing all record fields
|
boolean |
equals(ActivityRecord record)
Checks if this record equals the record passed
|
int |
getBatteryLevel()
Returns the current battery level
|
void |
setBatteryLevel(int level)
Sets the current battery level
|
static void |
setLocalTimeZone(TimeZone newLocalTimeZone)
Set the local time zone
|
void |
setUtcTime(long utcTime)
Set the UTC date time stamp
|
public static final int INVALID
protected static TimeZone localTimeZone
protected static TimeZone utcTimeZone
protected hirondelle.date4j.DateTime dateTime
protected int batteryLevel
public ActivityRecord()
public int compareTo(ActivityRecord other)
compareTo
in interface Comparable<ActivityRecord>
public static void setLocalTimeZone(TimeZone newLocalTimeZone)
newLocalTimeZone
- The new local timezone to usepublic void setUtcTime(long utcTime)
utcTime
- The local time, in seconds (epoch)public void setBatteryLevel(int level)
level
- Level in %public int getBatteryLevel()
public boolean equals(ActivityRecord record)
record
- Record to compare topublic void dumpRecordCsvHeader(Writer writer) throws IOException
writer
- Writer to dump toIOException
- Thrown when an error occurs during writingpublic void dumpRecordCsv(Writer writer) throws IOException
writer
- Writer to dump toIOException
- Thrown when an error occurs during writingCopyright © 2020. All rights reserved.