public class Sample extends Object
Filter
.Constructor and Description |
---|
Sample(org.json.JSONObject json)
Creates
Sample object from JSON representation. |
Sample(long time)
Creates
Sample object with a timestamp in milliseconds epoch time. |
Modifier and Type | Method and Description |
---|---|
long |
time()
Gets the timestamp of the measurement sample in milliseconds epoch time.
|
org.json.JSONObject |
toJSON()
Gets a JSON representation of the
Sample object. |
public Sample(long time)
Sample
object with a timestamp in milliseconds epoch time.time
- Timestamp of position measurement in milliseconds epoch time.public Sample(org.json.JSONObject json) throws org.json.JSONException
Sample
object from JSON representation.json
- JSON representation of a sample.org.json.JSONException
- thrown on JSON extraction or parsing error.Copyright © 2016. All rights reserved.