Coordinating

public protocol Coordinating : Coordinated, HasEvents

This protocol is the base for every Coordinator, which is to encapsulate the rootViewController and be able to be coordinated by a parent Coordinator

  • Unique string to identify specific Coordinator instance.

    By default it will be the String representation of the Coordinator’s subclass. If you directly instantiate Coordinator<T>, then you need to set it manually.

    Declaration

    Swift

    var identifier: String { get }
  • Bool indicating if Coordinator is started.

    Declaration

    Swift

    var isStarted: Bool { get }
  • Starts the Coordinator.

    Override this method if you want to perform any setup before the Coordinator presents anything.

    Declaration

    Swift

    func start(with completion: @escaping () -> Void)
  • Stops the Coordinator.

    Override this method to perform any logic before the Coordinator is deinitialized

    Declaration

    Swift

    func stop(with completion: @escaping () -> Void)
  • Activate Coordinator which was started before.

    This method is used when the Coordinator is visible again, giving you the chanee to do things like refreshing data, track screen, etc.

    Declaration

    Swift

    func activate()
  • Returns the Coordinator rootViewController

    Declaration

    Swift

    func getRootViewController() -> UIViewController