TKUIRoutingResultsCard
public class TKUIRoutingResultsCard : TKUITableCard
extension TKUIRoutingResultsCard: UITableViewDelegate
extension TKUIRoutingResultsCard: TKUIRoutingQueryInputCardDelegate
extension TKUIRoutingResultsCard: TKUITimePickerSheetDelegate
An interactive card for displaying routing results, including updating from/to location, time and selected modes.
Can be used standalone or via TKUIRoutingResultsViewController
.
-
Undocumented
Declaration
Swift
public static var config: TKUIRoutingResultsCard.Configuration
-
Undocumented
Declaration
Swift
public weak var resultsDelegate: TKUIRoutingResultsCardDelegate?
-
Set this callback to provide a custom handler for what should happen when a user selects a trip.
If not provided, or you return
true
it will lead to the standard of pushing aTKUITripOverviewCard
. Returningfalse
will do nothing, i.e., the callback should handle displaying the trip.Declaration
Swift
public var onSelection: ((Trip) -> Bool)?
-
Initializes and returns a newly allocated card showing results of routing from current location to a specified destination. The card will be placed at the specified initial position.
If the initial card position is not provided to the initializer, the value specified in the global configuration will be used. The default position is
.peaking
.Declaration
Swift
public init(destination: MKAnnotation, origin: MKAnnotation? = nil, zoomToDestination: Bool = true, initialPosition: TGCardPosition? = nil)
Parameters
destination
The destination of the routing request.
origin
Optionally, the origin lf the routing request. if not supplied, will use current location.
zoomToDestination
Whether the map should zoom to
destination
immediately. (Defaults totrue
if not provided.)initialPosition
The initial position at which the card is placed when it’s displayed.
-
Undocumented
Declaration
Swift
public init(request: TripRequest, editable: Bool = true)
-
Declaration
Swift
public override var preferredView: UIView? { get }
-
Declaration
Swift
override public func didBuild(tableView: UITableView, cardView: TGCardView)
-
Declaration
Swift
public override func willAppear(animated: Bool)
-
Declaration
Swift
public override func didAppear(animated: Bool)
-
Declaration
Swift
public override func traitCollectionDidChange(_ previousTraitCollection: UITraitCollection?)
-
Declaration
Swift
public override func willDisappear(animated: Bool)
-
Undocumented
Declaration
Swift
public override var keyCommands: [UIKeyCommand]? { get }
-
Undocumented
Declaration
Swift
override public func canPerformAction(_ action: Selector, withSender sender: Any?) -> Bool
-
Undocumented
Declaration
Swift
@objc public func debugActionCopyPrimaryRequest(_ sender: AnyObject?)
-
Undocumented
Declaration
Swift
typealias TripGroupAction = TKUICardAction<TKUIRoutingResultsCard, TripGroup>
-
Enumeration used when the user taps a button to get help, see
See moreTKUIRoutingResultsCard.Configuration.contactCustomerSupport
Declaration
Swift
enum SupportType
-
Configuration of any
TKUIRoutingResultsCard
.This isn’t created directly, but rather you modify the static instance accessible from
See moreTKUIRoutingResultsCard.config
.Declaration
Swift
struct Configuration
-
Undocumented
See moreDeclaration
Swift
public struct CustomItem : Hashable
-
Undocumented
Declaration
Swift
public func tableView(_ tableView: UITableView, viewForFooterInSection section: Int) -> UIView?
-
Undocumented
Declaration
Swift
public func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat
-
Undocumented
Declaration
Swift
public func tableView(_ tableView: UITableView, estimatedHeightForFooterInSection section: Int) -> CGFloat
-
Undocumented
Declaration
Swift
public func tableView(_ tableView: UITableView, viewForHeaderInSection section: Int) -> UIView?
-
Undocumented
Declaration
Swift
public func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat
-
Undocumented
Declaration
Swift
public func tableView(_ tableView: UITableView, estimatedHeightForHeaderInSection section: Int) -> CGFloat
-
Undocumented
Declaration
Swift
public func tableView(_ tableView: UITableView, contextMenuConfigurationForRowAt indexPath: IndexPath, point: CGPoint) -> UIContextMenuConfiguration?
-
Undocumented
Declaration
Swift
public func routingQueryInput(card: TKUIRoutingQueryInputCard, selectedOrigin origin: MKAnnotation, destination: MKAnnotation)
-
Undocumented
Declaration
Swift
public func timePicker(_ picker: TKUITimePickerSheet, pickedDate: Date, for type: TKTimeType)
-
Undocumented
Declaration
Swift
public func timePickerRequestsResign(_ pickerSheet: TKUITimePickerSheet)
-
Undocumented
Declaration
Swift
public func refreshForUpdatedModes()