Other Protocols

The following protocols are available globally.

  • Represents any action that has to be applied to the UIViewController after it has been built (eg: push to navigation stack, present modally, push to tab, etc)

    See more

    Declaration

    Swift

    public protocol AbstractAction
  • Base protocol for all types of factories. An instance that extends AbstractFactory builds a UIViewController that will later be integrated into the stack by the Router

    See more

    Declaration

    Swift

    public protocol AbstractFactory
  • Provides universal properties and methods of the ContainerViewController instance.

    See more

    Declaration

    Swift

    public protocol ConcreteContainerAdapter : ContainerAdapter
  • Custom ContainerViewControllers created outside of the library should extend this protocol, so DefaultContainerAdapterLocator could provide their ContainerAdapter to the DefaultRouter and other library’s instances when needed.

    NB: If you want to substitute the ContainerAdapter for the container view controllers that are handled by library such as UINavigationController you may create the extensions for such container view controllers in your project.

     public extension UINavigationController: CustomContainerViewController {
    
         var adapter: ContainerAdapter {
             return CustomNavigationAdapter(with: self)
         }
    
     }
    
    See more

    Declaration

    Swift

    public protocol CustomContainerViewController : ContainerViewController
  • Provides universal properties and methods of the ContainerViewController instance.

    ContainerViewControllers are different from the simple ones in that they can contain child view controllers which are also containers or simple ones. These view controllers are available out of the box: UINavigationController, UITabBarController and so on, but there can be custom ones created as well.

    All the container view controller have the following properties:

    1. The list of all the view controllers that they contain.
    2. One or more view controllers are currently visible.
    3. They can make one of these view controllers visible.
    4. They can replace all of their contained view controllers.
    See more

    Declaration

    Swift

    public protocol ContainerAdapter
  • Provides ContainerAdapter instance.

    See more

    Declaration

    Swift

    public protocol ContainerAdapterLocator
  • A helper protocol to the ContainerFactory protocol. If a container does not need to deal with the children view controller creation, SimpleContainerFactory will handle integration of the children view controllers.

    See more

    Declaration

    Swift

    public protocol SimpleContainerFactory : ContainerFactory
  • StackIterator protocol

    See more

    Declaration

    Swift

    public protocol StackIterator
  • Provides UIWindow

    See more

    Declaration

    Swift

    public protocol WindowProvider
  • The router implementing this protocol should support global tasks.

    See more

    Declaration

    Swift

    public protocol InterceptableRouter : Router
  • Helper instance used to update the stack of UIViewControllers

    See more

    Declaration

    Swift

    public protocol StackPresentationHandler
  • The Protocol that explains to the library that entity should be ignored.

    Declaration

    Swift

    public protocol NilEntity