SessionClient class abstract

Interface to the Session resource.

Constructors

SessionClient()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

get(int id, {DateTime? ifModifiedSince, String? eTag}) Future<CacheableResource<UserSessionModel>>
Gets a session with the given id. It accepts both ifModifiedSince and etag. If both are provided it will favour ifModifiedSince.
getForUser(int userId, int id, {DateTime? ifModifiedSince, String? eTag}) Future<CacheableResource<UserSessionModel>>
Get the public version of a session for the given ID. This is a helper method for some of the other overloads to assist with the cache control parameters. It accepts both
list({DateTime? from, DateTime? to, String? eTag}) Future<CacheableResource<List<UserSessionModel>>>
Retrieve a list of sessions with a start date between the from and to dates, inclusive. The maximum difference between the from and to dates is 31 days.
listForCohort(DateTime from, DateTime to, Studio studio, {String? etag, PaginationRequest? pagination}) Future<CacheableResource<PagedList<SessionModel>>>
Retrieve a list of sessions with a start date between the from and to dates, inclusive. The maximum difference between the from and to dates is 31 days.
listHeartRateZoneSummaries(int id, {DateTime? ifModifiedSince, String? eTag}) Future<CacheableResource<HeartRateZoneSummariesModel>>
Retrieve the list of heart rate zone summaries for a given session id.
listHeartRateZoneSummariesForUser(int userId, int id, {DateTime? ifModifiedSince, String? eTag}) Future<CacheableResource<HeartRateZoneSummariesModel>>
Retrieve the list of heart rate zone summaries associated with a specific session.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
update(int id, {required ActivityType activityType, required OffsetDateTime startedOnLocal, required OffsetDateTime endedOnLocal, required int activeDurationInSeconds, required SessionPrivacy privacy}) Future<void>
Updates a session based on it's ID. All parameters will be updated, even if they are null.

Operators

operator ==(Object other) bool
The equality operator.
inherited