GoogleRidesharingConsumer Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
GMTSTripWaypoint
Object that describes a vehicle stop on its route.
For a trip with multiple passengers,
this point might be an intermediate stop or the end of a trip.
-
The location associated with the ‘tripWaypoint’.
-
The trip ID associated with the waypoint.
Declaration
Swift
var tripID: String? { get }
-
The type of the trip waypoint.
-
The path distance calculated by the Fleet Engine from the previous waypoint on a path to
the current waypoint.
Declaration
Swift
var distanceToPreviousWaypointInMeters: Int32 { get }
Objective-C
@property (nonatomic, readonly) int32_t distanceToPreviousWaypointInMeters;
-
The estimated time of arrival to this waypoint.
Declaration
Swift
var eta: TimeInterval { get }
Objective-C
@property (nonatomic, readonly) NSTimeInterval ETA;
-
The path calculated by the server from the previous waypoint
to the current waypoint encoded as an array of LatLng.
Declaration
Swift
var routeFromPreviousWaypoint: [GMTSLatLng]? { get }
Objective-C
@property (nonatomic, readonly, nullable) NSArray<GMTSLatLng *> *routeFromPreviousWaypoint;
-
The traffic data for the path leading to this waypoint.
Declaration
Objective-C
@property (nonatomic, readonly, nullable) GMTSTrafficData *trafficData;
-
Parameters
location
|
The latitude and longitude associated with the waypoint.
|
tripID
|
The ID of the trip which associated with the waypoint.
|
waypointType
|
The type of terminal associated with the waypoint.
|
distanceToPreviousWaypointInMeters
|
The path distance calculated by Fleet Engine from the
previous waypoint to the current waypoint.
|
ETA
|
The estimated time of arrival to the waypoint.
|
-
Use -initWithLocation:tripID:waypointType:distanceMeters:eta:
instead.
Declaration
Objective-C
- (null_unspecified instancetype)init;
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-27 UTC.
[null,null,["Last updated 2025-08-27 UTC."],[[["\u003cp\u003e\u003ccode\u003eGMTSTripWaypoint\u003c/code\u003e describes a vehicle's stop on a route, potentially being an intermediate or final destination for trips with multiple passengers.\u003c/p\u003e\n"],["\u003cp\u003eEach \u003ccode\u003eGMTSTripWaypoint\u003c/code\u003e includes a location, trip ID, waypoint type, distance from the previous waypoint in meters, and estimated time of arrival (ETA).\u003c/p\u003e\n"],["\u003cp\u003eThe object provides details about the route from the previous waypoint, encoded as an array of LatLng, and also provides access to traffic data.\u003c/p\u003e\n"],["\u003cp\u003eYou can instantiate a \u003ccode\u003eGMTSTripWaypoint\u003c/code\u003e using \u003ccode\u003e-initWithLocation:tripID:waypointType:distanceToPreviousWaypointInMeters:ETA:\u003c/code\u003e and pass it the location, trip ID, waypoint type, distance from previous waypoint and the ETA.\u003c/p\u003e\n"],["\u003cp\u003eThe object is immutable, since it's based on \u003ccode\u003eGMTCImmutableData\u003c/code\u003e, and the default \u003ccode\u003e-init\u003c/code\u003e function is unavailable, making it mandatory to use the correct constructor.\u003c/p\u003e\n"]]],[],null,["# GoogleRidesharingConsumer Framework Reference\n\nGMTSTripWaypoint\n================\n\n @interface GMTSTripWaypoint : ../Classes/GMTCImmutableData.html\n\nObject that describes a vehicle stop on its route.\nFor a trip with multiple passengers,\nthis point might be an intermediate stop or the end of a trip.\n- `\n ``\n ``\n `\n\n ### [location](#/c:objc(cs)GMTSTripWaypoint(py)location)\n\n `\n ` \n The location associated with the 'tripWaypoint'. \n\n #### Declaration\n\n Swift \n\n var location: ../Classes/GMTSTerminalLocation.html? { get }\n\n Objective-C \n\n @property (nonatomic, readonly, nullable) ../Classes/GMTSTerminalLocation.html *location;\n\n- `\n ``\n ``\n `\n\n ### [tripID](#/c:objc(cs)GMTSTripWaypoint(py)tripID)\n\n `\n ` \n The trip ID associated with the waypoint. \n\n #### Declaration\n\n Swift \n\n var tripID: String? { get }\n\n Objective-C \n\n @property (nonatomic, readonly, nullable) ../Type-Definitions/GMTCFleetEngineIDString.html *tripID;\n\n- `\n ``\n ``\n `\n\n ### [waypointType](#/c:objc(cs)GMTSTripWaypoint(py)waypointType)\n\n `\n ` \n The type of the trip waypoint. \n\n #### Declaration\n\n Swift \n\n var waypointType: ../Enums/GMTSTripWaypointType.html { get }\n\n Objective-C \n\n @property (nonatomic, readonly) ../Enums/GMTSTripWaypointType.html waypointType;\n\n- `\n ``\n ``\n `\n\n ### [distanceToPreviousWaypointInMeters](#/c:objc(cs)GMTSTripWaypoint(py)distanceToPreviousWaypointInMeters)\n\n `\n ` \n The path distance calculated by the Fleet Engine from the previous waypoint on a path to\n the current waypoint. \n\n #### Declaration\n\n Swift \n\n var distanceToPreviousWaypointInMeters: Int32 { get }\n\n Objective-C \n\n @property (nonatomic, readonly) int32_t distanceToPreviousWaypointInMeters;\n\n- `\n ``\n ``\n `\n\n ### [ETA](#/c:objc(cs)GMTSTripWaypoint(py)ETA)\n\n `\n ` \n The estimated time of arrival to this waypoint. \n\n #### Declaration\n\n Swift \n\n var eta: TimeInterval { get }\n\n Objective-C \n\n @property (nonatomic, readonly) NSTimeInterval ETA;\n\n- `\n ``\n ``\n `\n\n ### [routeFromPreviousWaypoint](#/c:objc(cs)GMTSTripWaypoint(py)routeFromPreviousWaypoint)\n\n `\n ` \n The path calculated by the server from the previous waypoint\n to the current waypoint encoded as an array of LatLng. \n\n #### Declaration\n\n Swift \n\n var routeFromPreviousWaypoint: [../Classes/GMTSLatLng.html]? { get }\n\n Objective-C \n\n @property (nonatomic, readonly, nullable) NSArray\u003c../Classes/GMTSLatLng.html *\u003e *routeFromPreviousWaypoint;\n\n- `\n ``\n ``\n `\n\n ### [trafficData](#/c:objc(cs)GMTSTripWaypoint(py)trafficData)\n\n `\n ` \n The traffic data for the path leading to this waypoint. \n\n #### Declaration\n\n Swift \n\n var trafficData: ../Classes/GMTSTrafficData.html? { get }\n\n Objective-C \n\n @property (nonatomic, readonly, nullable) ../Classes/GMTSTrafficData.html *trafficData;\n\n- `\n ``\n ``\n `\n\n ### [-initWithLocation:tripID:waypointType:distanceToPreviousWaypointInMeters:ETA:](#/c:objc(cs)GMTSTripWaypoint(im)initWithLocation:tripID:waypointType:distanceToPreviousWaypointInMeters:ETA:)\n\n `\n ` \n Instantiates the object. \n\n #### Declaration\n\n Swift \n\n init(location: ../Classes/GMTSTerminalLocation.html?, tripID: String?, waypointType: ../Enums/GMTSTripWaypointType.html, distanceToPreviousWaypointInMeters: Int32, eta ../Classes/GMTSTripWaypoint.html#/c:objc(cs)GMTSTripWaypoint(py)ETA: TimeInterval)\n\n Objective-C \n\n - (nonnull instancetype)initWithLocation:\n (nullable ../Classes/GMTSTerminalLocation.html *)location\n tripID:\n (nullable ../Type-Definitions/GMTCFleetEngineIDString.html *)tripID\n waypointType:(../Enums/GMTSTripWaypointType.html)waypointType\n distanceToPreviousWaypointInMeters:\n (int32_t)distanceToPreviousWaypointInMeters\n ETA:(NSTimeInterval)ETA;\n\n #### Parameters\n\n |--------------------------------------------|--------------------------------------------------------------------------------------------------|\n | ` `*location*` ` | The latitude and longitude associated with the waypoint. |\n | ` `*tripID*` ` | The ID of the trip which associated with the waypoint. |\n | ` `*waypointType*` ` | The type of terminal associated with the waypoint. |\n | ` `*distanceToPreviousWaypointInMeters*` ` | The path distance calculated by Fleet Engine from the previous waypoint to the current waypoint. |\n | ` `*ETA*` ` | The estimated time of arrival to the waypoint. |\n\n- `\n ``\n ``\n `\n\n ### [-init](#/c:objc(cs)GMTSTripWaypoint(im)init)\n\n `\n ` \n Unavailable \n Use `-initWithLocation:tripID:waypointType:distanceMeters:eta:` instead. \n\n #### Declaration\n\n Objective-C \n\n - (null_unspecified instancetype)init;"]]