RouteHandler

open class RouteHandler<R> where R : RouteType

Route Handler

This delegate is provided as a generic base class.

Feel free to inherit from this base class and override the methods prepareForTransition(to:) and transition(for:).

Constructor

  • Constructor. Required to set class visibility to public.

    Declaration

    Swift

    public init()

Methods

  • Configure the view controller for your route here.

    You can either give it the container (i.e. Navigation Controller) or an instance of a single view controller.

    Note

    Throw any Error here to cancel the transition.

    Declaration

    Swift

    open func prepareDestination(for route: R) throws -> UIViewController
  • Presentation transition type for Route.

    Declaration

    Swift

    open func transition(for route: R) -> RouteTransition