# GoogleRidesharingConsumer Framework Reference

# Classes

The following classes are available globally.
- `


  ### [GMTCAuthorizationContext](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCAuthorizationContext)


  ` An immutable object representing the context needed to fetch an auth token.

  #### Declaration

  Swift

      class GMTCAuthorizationContext : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTCAuthorizationContext : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTCConsumerMapStyleCoordinator](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCConsumerMapStyleCoordinator)


  ` Container class for the custom UI options for elements of the GMTCMapView.

  #### Declaration

  Swift

      class GMTCConsumerMapStyleCoordinator : NSObject

  Objective-C

      @interface GMTCConsumerMapStyleCoordinator : NSObject

- `


  ### [GMTCImmutableData](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData)


  ` A base class of immutable data, subclass must implement the `isEqual:` and `hash` of the
  `NSObject` protocol.

  #### Declaration

  Swift

      class GMTCImmutableData : NSObject, NSCopying, NSSecureCoding

  Objective-C

      @interface GMTCImmutableData : NSObject <NSCopying, NSSecureCoding>

- `


  ### [GMTCJourneySharingSession](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCJourneySharingSession)


  `

  #### Declaration

  Swift

      class GMTCJourneySharingSession : NSObject, https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Protocols/GMTCMapViewSession

  Objective-C

      @interface GMTCJourneySharingSession : NSObject <https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Protocols/GMTCMapViewSession>

      /** Delegate of the current journey sharing session. */
      @property(nonatomic, nullable, weak) id<https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Protocols/GMTCMapViewSessionDelegate> delegate;

      /**
       * Returns the current session state. The possible state can be referenced from
       * `GMTCMapViewSessionState`.
       */
      @property(nonatomic, readonly) https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Enums/GMTCMapViewSessionState state;

      /** Returns the host map view of the current session. */
      @property(nonatomic, nullable, weak, readonly) https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMapView *hostMapView;

      /** Returns the associated trip session. */
      @property(nonatomic, readonly) https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModel *tripModel;

      /**
       * Initializes the session object.
       *
       * @param tripModel The target trip request.
       */
      - (instancetype)initWithTripModel:(https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModel *)tripModel;

      - (instancetype)init NS_UNAVAILABLE;

      @end

[## GMTCMapView](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes#/GMTCMapView)

- `


  ### [GMTCMapView](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMapView)


  ` This class represents the main view in the Consumer SDK for iOS.
  You can use this class to create a customizable map so that your users can
  use the `consumerMapStylecoordinator` to create custom markers and polylines.

  Note: You should instantiate this map via the default constructor `[[GMTCMapView alloc]
  initWithFrame:]`.

  `GMTCMapView` can be read and modified only from the main thread, similar to `GMSMapView` and all
  UIKit objects. Calling these methods from another thread results in an exception or undefined
  behavior.

  #### Declaration

  Swift

      class GMTCMapView : GMSMapView

  Objective-C

      @interface GMTCMapView : GMSMapView

- `


  ### [GMTCMarkerStyleOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMarkerStyleOptions)


  ` Data object that holds custom marker properties from the client application.

  #### Declaration

  Swift

      class GMTCMarkerStyleOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData, NSCopying, NSMutableCopying

  Objective-C

      @interface GMTCMarkerStyleOptions
          : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData <NSCopying, NSMutableCopying>

- `


  ### [GMTCMutableMarkerStyleOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMutableMarkerStyleOptions)


  ` Mutable data object that holds marker's customization properties.
  Note: When applying the style options for a marker with the
  `GMTCCustomizableMarkerTypeTripVehicle` type, you must explicitly
  set the `isFlat` property to YES. Otherwise, when the map is rotated in 3D
  mode, the vehicle heading won't be aligned with the rotated direction.

  #### Declaration

  Swift

      class GMTCMutableMarkerStyleOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMarkerStyleOptions

  Objective-C

      @interface GMTCMutableMarkerStyleOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMarkerStyleOptions

- `


  ### [GMTCPolylineStyleOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCPolylineStyleOptions)


  ` Data object that holds polyline customization properties.

  #### Declaration

  Swift

      class GMTCPolylineStyleOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData, NSCopying, NSMutableCopying

  Objective-C

      @interface GMTCPolylineStyleOptions
          : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData <NSCopying, NSMutableCopying>

- `


  ### [GMTCMutablePolylineStyleOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMutablePolylineStyleOptions)


  ` Mutable data object that holds polyline customization properties.

  #### Declaration

  Swift

      class GMTCMutablePolylineStyleOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCPolylineStyleOptions

  Objective-C

      @interface GMTCMutablePolylineStyleOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCPolylineStyleOptions

- `


  ### [GMTCServices](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCServices)


  ` Service class for the Google Consumer Ridesharing SDK for iOS.

  #### Declaration

  Swift

      class GMTCServices : NSObject

  Objective-C

      @interface GMTCServices : NSObject

- `


  ### [GMTCTripModel](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModel)


  ` A class representing a trip session. A trip session will provide trip info update periodically
  after started, it can be either a ridesharing or a delivery trip, and each trip session is
  identified by a TripName.

  #### Declaration

  Swift

      class GMTCTripModel : NSObject

  Objective-C

      @interface GMTCTripModel : NSObject

- `


  ### [GMTCTripModelOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModelOptions)


  ` Object that for configuring the `https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModel`.

  #### Declaration

  Swift

      class GMTCTripModelOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequestOptions, NSMutableCopying

  Objective-C

      @interface GMTCTripModelOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequestOptions <NSMutableCopying>

- `


  ### [GMTCMutableTripModelOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMutableTripModelOptions)


  ` Mutable version of `https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModelOptions`.

  #### Declaration

  Swift

      class GMTCMutableTripModelOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModelOptions

  Objective-C

      @interface GMTCMutableTripModelOptions : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripModelOptions

- `


  ### [GMTCTripRequest](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripRequest)


  ` A request object for specifying parameters to get an active trip.

  #### Declaration

  Swift

      class GMTCTripRequest : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequest, NSCopying, NSMutableCopying

  Objective-C

      @interface GMTCTripRequest : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequest <NSCopying, NSMutableCopying>

- `


  ### [GMTCMutableTripRequest](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCMutableTripRequest)


  ` Mutable version of `https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripRequest`.

  #### Declaration

  Swift

      class GMTCMutableTripRequest : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripRequest

  Objective-C

      @interface GMTCMutableTripRequest : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripRequest

- `


  ### [GMTCTripService](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCTripService)


  ` Provides methods for accessing trip session(s).

  #### Declaration

  Swift

      class GMTCTripService : NSObject

  Objective-C

      @interface GMTCTripService : NSObject

- `


  ### [GMTSLatLng](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSLatLng)


  ` Object representing the latitude and longitude.

  #### Declaration

  Swift

      class GMTSLatLng : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSLatLng : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSRequest](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequest)


  ` Request object that is an abstract class.

  #### Declaration

  Swift

      class GMTSRequest : NSObject, NSCopying, NSMutableCopying

  Objective-C

      @interface GMTSRequest : NSObject <NSCopying, NSMutableCopying>

- `


  ### [GMTSRequestHeader](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequestHeader)


  ` A request header object contains common fields for a request.

  #### Declaration

  Swift

      class GMTSRequestHeader : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSRequestHeader : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSRequestOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequestOptions)


  ` An object for defining the request options. This is an abstract class.
  This object can be a part of a `https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSRequest`, to specify extra prarameters of a request.

  #### Declaration

  Swift

      class GMTSRequestOptions : NSObject, NSCopying, NSMutableCopying

  Objective-C

      @interface GMTSRequestOptions : NSObject <NSCopying, NSMutableCopying>

- `


  ### [GMTSSpeedReadingSpan](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSSpeedReadingSpan)


  ` A data object that holds the traffic conditions for a contiguous segment of a polyline.

  #### Declaration

  Swift

      class GMTSSpeedReadingSpan : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSSpeedReadingSpan : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSTerminalLocation](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSTerminalLocation)


  ` Object representing information that identifies a terminal location.

  #### Declaration

  Swift

      class GMTSTerminalLocation : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSTerminalLocation : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSTimestamp](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSTimestamp)


  ` Object representing a timestamp.

  #### Declaration

  Swift

      class GMTSTimestamp : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSTimestamp : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSTrafficData](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSTrafficData)


  ` An object that holds the traffic data for a stretch of road.

  #### Declaration

  Swift

      class GMTSTrafficData : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSTrafficData : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSTrip](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSTrip)


  ` Object that contains logistical information about a trip such as
  `vehicleId`, type of trip, pickup or dropoff times, and route.

  #### Declaration

  Swift

      class GMTSTrip : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSTrip : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSTripWaypoint](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/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.

  #### Declaration

  Swift

      class GMTSTripWaypoint : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSTripWaypoint : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

[## GMTSVehicleAttributeKeyValuePair](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes#/GMTSVehicleAttributeKeyValuePair)

- `


  ### [GMTSVehicleAttributeKeyValuePair](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSVehicleAttributeKeyValuePair)


  ` Object that contains a vehicle attribute key/value pair.

  #### Declaration

  Swift

      class GMTSVehicleAttributeKeyValuePair : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSVehicleAttributeKeyValuePair : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

[## GMTSVehicle](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes#/GMTSVehicle)

- `


  ### [GMTSVehicle](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSVehicle)


  ` Object that contains functional data related to a vehicle. This data can be profile data, such as
  the max capacity, or tracking data, such as current trips and location.

  #### Declaration

  Swift

      class GMTSVehicle : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSVehicle : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSVehicleLocation](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSVehicleLocation)


  ` Object that contains the location information for the vehicle that describes
  the heading, speed, and time when this information was retrieved.

  #### Declaration

  Swift

      class GMTSVehicleLocation : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSVehicleLocation : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSVehicleLocationOptions](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSVehicleLocationOptions)


  ` This class defines initialization-time options for `https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSVehicleLocation`.

  #### Declaration

  Swift

      class GMTSVehicleLocationOptions : NSObject

  Objective-C

      @interface GMTSVehicleLocationOptions : NSObject

- `


  ### [GMTSVehicleMatch](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSVehicleMatch)


  ` Object that contains the vehicle's information, ETA, and distance
  calculations for a vehicle that matches the `SearchVehiclesRequest`.

  #### Declaration

  Swift

      class GMTSVehicleMatch : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSVehicleMatch : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSVehicleType](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSVehicleType)


  ` Data object containing information about the type of the vehicle.

  #### Declaration

  Swift

      class GMTSVehicleType : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSVehicleType : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

- `


  ### [GMTSWaypoint](https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTSWaypoint)


  ` Object representing an intermediate point along a route.

  #### Declaration

  Swift

      class GMTSWaypoint : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData

  Objective-C

      @interface GMTSWaypoint : https://developers.google.com/maps/documentation/mobility/journey-sharing/on-demand/reference/ios/Classes/GMTCImmutableData