climbSections property

List<ClimbSection> get climbSections

Get list of route climb sections.

Climb sections are the difficult climbing parts of a route. The climb categories are defined in Grade.

If none of the climbing parts of a route are at least Grade.grade4, the list will be empty.

Returns

  • The climb sections list

Throws

  • An exception if it fails.

Implementation

List<ClimbSection> get climbSections {
  final OperationResult resultString = objectMethod(
    _pointerId,
    'RouteTerrainProfile',
    'getClimbSections',
  );

  final List<dynamic> listJson = resultString['result'];
  final List<ClimbSection> retList = listJson
      .map(
        (final dynamic categoryJson) => ClimbSection.fromJson(categoryJson),
      )
      .toList();
  return retList;
}