CartoType .NET API 7.8.2, 2022-03-25
for development in C#, Visual Basic and other .NET languages
|
Information about an entire route. More...
#include <CartoTypeWrapper.h>
Public Member Functions | |
Geometry ^ | GetGeometry () |
Gets the geometry of the route. | |
RouteProfile ^ | GetProfile () |
Gets the profile used to create this route. | |
double | GetDistance () |
Gets the distance of the route in metres. | |
double | GetTime () |
Gets the estimated time taken to traverse the route in seconds. | |
int | GetRouteSegmentCount () |
Gets the number of route segments. | |
RouteSegment ^ | GetRouteSegment (int aIndex) |
Gets a route segment. | |
double | GetTollRoadDistance () |
Returns the total distance in metres of the parts of the route that are on toll roads. | |
NearestSegmentInfo ^ | GetNearestSegment (double aX, double aY, int aSection, double aPreviousDistanceAlongRoute) |
Gets information about the nearest route segment to a point given in map coordinates. More... | |
NearestSegmentInfo ^ | GetPointAtDistance (double aDistanceInMeters) |
Gets information about a point a certain distance along a route. | |
NearestSegmentInfo ^ | GetPointAtTime (double aTimeInSeconds) |
Gets information about a point a certain estimated time along a route. | |
virtual int | ContourCount () |
Gets the number of contours (sub-paths). More... | |
virtual int | PointCount (int aContourIndex) |
Gets the number of points in a contour. More... | |
virtual void | GetPoint (int aContourIndex, int aPointIndex, PathPoint^ aPoint) |
Gets a point given its contour and point indexes. More... | |
int | ContourCount () |
Gets the number of contours (sub-paths). More... | |
int | PointCount (int aContourIndex) |
Gets the number of points in a contour. More... | |
void | GetPoint (int aContourIndex, int aPointIndex, PathPoint^ aPoint) |
Gets a point given its contour and point indexes. More... | |
Information about an entire route.
|
virtual |
Gets the number of contours (sub-paths).
Implements CartoType::Path.
NearestSegmentInfo ^ CartoType::Route::GetNearestSegment | ( | double | aX, |
double | aY, | ||
int | aSection, | ||
double | aPreviousDistanceAlongRoute | ||
) |
Gets information about the nearest route segment to a point given in map coordinates.
The parameter aSection gives the current route section (a part of the route between waypoints; simple routes have a single section). The returned segment will always be in the current section or a following section. It is theoretically possible for a section to be completely skipped if it is very short or of zero length, so there is no constraint that section 0 must be followed by section 1 and not by section 2, etc. If aSection is negative it is ignored and the returned segment may be in any section.
The parameter aPreviousDistanceAlongRoute should be provided (set to a value greater than zero) for multi-section routes, so that the correct route segment can be chosen if the route doubles back on itself. Positions further along the route will be given preference over those earlier in the route.
|
virtual |
Gets a point given its contour and point indexes.
Implements CartoType::Path.
|
virtual |
Gets the number of points in a contour.
Implements CartoType::Path.