com.samsung.android.sdk.healthdata
Class HealthDataResolver.ReadResult
- java.lang.Object
-
- com.samsung.android.sdk.healthdata.HealthResultHolder.BaseResult
-
- com.samsung.android.sdk.healthdata.HealthDataResolver.ReadResult
-
- All Implemented Interfaces:
- Parcelable, Closeable, AutoCloseable, Iterable<HealthData>
- Enclosing class:
- HealthDataResolver
public static class HealthDataResolver.ReadResult extends HealthResultHolder.BaseResult implements Iterable<HealthData>, Closeable
This class represents the result forHealthDataResolver.ReadRequest
. It is retrieved with Asynchronous request or synchronous request.
Each health data in the result can be checked withiterator()
andclose()
.- Since:
- 1.0.0
-
-
Field Summary
-
Fields inherited from class com.samsung.android.sdk.healthdata.HealthResultHolder.BaseResult
STATUS_CANCELED, STATUS_FAILED, STATUS_INVALID_INPUT_DATA, STATUS_OUT_OF_SPACE, STATUS_SUCCESSFUL, STATUS_UNKNOWN
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description void
close()
Closes this result, releasing all of its resources and making it completely invalid.String
getDataType()
Gets a data type for the requested health data.Cursor
getResultCursor()
Gets aCursor
object for the requested health data.Iterator<HealthData>
iterator()
Returns an iterator over theHealthData
objects in this result in proper sequence.-
Methods inherited from class com.samsung.android.sdk.healthdata.HealthResultHolder.BaseResult
getCount, getStatus
-
-
-
-
Method Detail
-
getResultCursor
public Cursor getResultCursor()
Gets aCursor
object for the requested health data. Check health data of the result as moving it to the next.- Returns:
- The
Cursor
object, or
null
if the request doesn't work caused by an unknown error. - Since:
- 1.0.0
-
getDataType
public String getDataType()
Gets a data type for the requested health data.- Returns:
- The data type
- Since:
- 1.0.0
-
iterator
public Iterator<HealthData> iterator()
Returns an iterator over theHealthData
objects in this result in proper sequence.- Returns:
- An iterator of this result.
- Since:
- 1.3.0
-
close
public void close()
Closes this result, releasing all of its resources and making it completely invalid.
Calling this method, the result will not be valid any more.- Since:
- 1.3.0
-
-