Even more documentation/specification

master
cpfeiffer 2016-08-27 20:14:42 +02:00
parent c2a509be74
commit 083d752011
2 changed files with 17 additions and 1 deletions

View File

@ -2,6 +2,22 @@ package nodomain.freeyourgadget.gadgetbridge.model;
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
/**
* The all-in-one interface for a sample measured by a device with
* one or more sensors.
*
* Each sample is the result of one or more measurements. The values are set for
* a specific point in time (see @{link #getTimestamp()}).
*
* If the sample relates to a user activity (e.g. sleeping, walking, running, ...)
* then the activity is provided through @{link #getKind()}.
*
* Methods will return @{link #NOT_MEASURED} in case no value is available for this
* sample.
*
* The frequency of samples, i.e. the how many samples are recorded per minute, is not specified
* and may vary.
*/
public interface ActivitySample extends TimeStamped {
int NOT_MEASURED = -1;

View File

@ -2,7 +2,7 @@ package nodomain.freeyourgadget.gadgetbridge.model;
public interface TimeStamped {
/**
* Timestamp of the sample, resolution is seconds!
* Unix timestamp of the sample, i.e. the number of seconds since 1970-01-01 00:00:00 UTC.
*/
int getTimestamp();
}