MMKRoutePosition
class MMKRoutePosition : NSObject |
Undocumented
Summary
Instance methods
func onRoute(withRouteId routeId: String) -> Bool |
func positionOnRoute(withRouteId routeId: String) -> MMKPolylinePosition? |
func advance(withDistance distance: Double) -> MMKRoutePosition |
func distanceToWith(to: MMKRoutePosition) -> NSNumber? |
func precedes(withAnother another: MMKRoutePosition) -> Bool |
func precedesOrEquals(withAnother another: MMKRoutePosition) -> Bool |
func equals(withAnother another: MMKRoutePosition) -> Bool |
func heading() -> Double |
func distanceToFinish() -> Double |
func timeToFinish() -> Double |
Properties
Instance methods
onRoute(withRouteId:)
func onRoute(withRouteId routeId: String) -> Bool |
Check if this position on the same route as passed.
positionOnRoute(withRouteId:)
func positionOnRoute(withRouteId routeId: String) -> MMKPolylinePosition? |
Return polyline position on route. If the position not on the passed route none will be returned.
advance(withDistance:)
func advance(withDistance distance: Double) -> MMKRoutePosition |
Create position shifted by distance. If the distance is more than remains route length, the end of the route will be returned. If the distance is less than a negative distance from the start, the beginning of the route will be returned.
distanceToWith(to:)
func distanceToWith(to: MMKRoutePosition) -> NSNumber? |
Distance to another point on the route. Return none if point on another route. May be less 0 if position "to" stay before this position.
precedes(withAnother:)
func precedes(withAnother another: MMKRoutePosition) -> Bool |
Determines if position precedes another position on the route. Throws if another position belongs to another route.
precedesOrEquals(withAnother:)
func precedesOrEquals(withAnother another: MMKRoutePosition) -> Bool |
Determines if position precedes or equals another position on the route. Throws if another position belongs to another route.
equals(withAnother:)
func equals(withAnother another: MMKRoutePosition) -> Bool |
Determines if position equals another position on the route. Throws if another position belongs to another route.
heading()
func heading() -> Double |
Heading movement on the route at this position. It is equal heading of the segment which is belonged position.
distanceToFinish()
func distanceToFinish() -> Double |
Distance to the end of the route.
timeToFinish()
func timeToFinish() -> Double |
Time to the end of the route.
Properties
point
var point: MMKPoint { get } |
As point on the map