DestinationUIKitCoordinator
@MainActor
public final class DestinationUIKitCoordinator : NSObject, DestinationUIKitCoordinating
This class coordinates the presentation of a Destination within the UIKit framework.
-
A reference to the base
ControllerDestinationInterfacingobject in a UIKit app.Declaration
Swift
@MainActor public weak var baseController: (any ControllerDestinationInterfacing)? -
A closure which is called when a Destination should be removed from the ecosystem, typically after it’s associated UI object is no longer being presented.
Declaration
Swift
@MainActor public var removeDestinationClosure: RemoveDestinationFromFlowClosure? -
The Destination that currently should be presented.
Declaration
Swift
@MainActor public var destinationToPresent: (any Destinationable)? -
A delegate protocol object which can subscribe to this object to receive updates about the status of destination presentations.
Declaration
Swift
@MainActor public weak var delegate: DestinationInterfaceCoordinatorDelegate? -
The initializer.
Declaration
Swift
@MainActor public init(baseController: (any ControllerDestinationInterfacing)? = nil)Parameters
baseControllerA reference to the root
ControllerDestinationInterfacingobject in a UIKit app. -
presentControllerDestination(destination:currentDestination: parentOfCurrentDestination: tabBarDestinationInViewHiearchy: configuration: ) Handles the presentation of a Destination’s associated
UIViewControllerin a UIKit app.Declaration
Swift
@MainActor public func presentControllerDestination<DestinationType: RoutableDestinations, ContentType: ContentTypeable, TabType: TabTypeable>( destination: (any ControllerDestinationable<DestinationType, ContentType, TabType>)? = nil, currentDestination: (any ControllerDestinationable)?, parentOfCurrentDestination: (any ControllerDestinationable)?, tabBarDestinationInViewHiearchy: (any TabBarControllerDestinationable)?, configuration: DestinationPresentation<DestinationType, ContentType, TabType>)Parameters
destinationThe Destination to present.
currentDestinationThe currently presented Destination.
parentOfCurrentDestinationThe parent of the current Destination.
configurationThe configuration object for this presentation.
-
UINavigationControllerDelegate delegate method
Declaration
Swift
@MainActor public func navigationController(_ navigationController: UINavigationController, animationControllerFor operation: UINavigationController.Operation, from fromVC: UIViewController, to toVC: UIViewController) -> UIViewControllerAnimatedTransitioning? -
UINavigationControllerDelegate delegate method
Declaration
Swift
@MainActor public func navigationController(_ navigationController: UINavigationController, willShow viewController: UIViewController, animated: Bool)
View on GitHub