C# Class Stravan.Json.SegmentService

Service implementation for segments in the Strava API
Inheritance: BaseService, ISegmentService
Datei anzeigen Open project: KristopherGBaker/Stravan Class Usage Examples

Public Methods

Method Description
Efforts ( int segmentId, int clubId = null, int athleteId = null, string athleteName = null, System.DateTime startDate = null, System.DateTime endDate = null, int startId = null, bool isBest = null, int offset = null ) : SegmentEfforts

Returns a list of matching Efforts on a Segment. The response includes the Id of the Effort, the elapsed time of the Effort, and the Id, Name, and Username of the Athlete who ride the Effort. Efforts are ordered by start date, oldest to newest.

Index ( string name, int offset = null ) : List

Searches for Segments by name. Returns a list of Segments. The response includes the Id and Name of each matching Segment.

SegmentService ( IStravaWebClient client ) : System

Initializes a SegmentService with the specified client

Show ( int id ) : Segment

Returns extended information for a Segment.

Method Details

Efforts() public method

Returns a list of matching Efforts on a Segment. The response includes the Id of the Effort, the elapsed time of the Effort, and the Id, Name, and Username of the Athlete who ride the Effort. Efforts are ordered by start date, oldest to newest.
public Efforts ( int segmentId, int clubId = null, int athleteId = null, string athleteName = null, System.DateTime startDate = null, System.DateTime endDate = null, int startId = null, bool isBest = null, int offset = null ) : SegmentEfforts
segmentId int Required. The Id of the Segment.
clubId int Optional. Id of the Club for which to search for member's Efforts.
athleteId int Optional. Id of the Athlete for which to search for Efforts.
athleteName string Optional. Username of the Athlete for which to search for Rides.
startDate System.DateTime Optional. Day on which to start search for Efforts. The date is the local time of when the effort started.
endDate System.DateTime Optional. Day on which to end search for Efforts. The date is the local time of when the effort started.
startId int Optional. Only return Effforts with an Id greater than or equal to the startId.
isBest bool Optional. Shows an best efforts per athlete sorted by elapsed time ascending (segment leaderboard).
offset int Optional. Any search will return at most 50 rows. To retrieve results after the 50th row use the offset parameter. For example, to retrieve rows 51-100 use an offset of 50.
return SegmentEfforts

Index() public method

Searches for Segments by name. Returns a list of Segments. The response includes the Id and Name of each matching Segment.
public Index ( string name, int offset = null ) : List
name string Required. Part of the name of the Segment to match.
offset int Optional. Any search will return at most 50 rows. To retrieve results after the 50th row use the offset parameter. For example, to retrieve rows 51-100 use an offset of 50.
return List

SegmentService() public method

Initializes a SegmentService with the specified client
public SegmentService ( IStravaWebClient client ) : System
client IStravaWebClient IStravaWebClient to use with the service
return System

Show() public method

Returns extended information for a Segment.
public Show ( int id ) : Segment
id int Required. The Id of the Effort.
return Segment