CompleteFactoryChainAssembly

public final class CompleteFactoryChainAssembly<FC, ChildVC, ChildContext> where FC : ContainerFactory, ChildVC : UIViewController

Builds the chain of assemblies to fulfill the ContainerFactory.

Methods

  • Adds a Factory that is going to be used as a child

    Declaration

    Swift

    public final func with<ChildFC: Factory, A: ContainerAction, T: ContextTransformer>(_ childFactory: ChildFC, using action: A, adapting transformer: T) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context>
        where
        T.TargetContext == ChildFC.Context, T.SourceContext == FC.Context, A.ViewController == FC.ViewController

    Parameters

    childFactory

    The instance of Factory.

    action

    The instance of Factory to be used to integrate the view controller produced by the factory.

  • Adds a ContainerFactory that is going to be used as a child

    Declaration

    Swift

    public final func with<ChildFC: ContainerFactory, A: ContainerAction, T: ContextTransformer>(_ childContainer: ChildFC, using action: A, adapting transformer: T) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context>
        where
        T.TargetContext == ChildFC.Context, T.SourceContext == FC.Context, A.ViewController == FC.ViewController

    Parameters

    childContainer

    The instance of ContainerFactory.

    action

    The instance of ContainerFactory to be used to integrate the view controller produced by the factory.

  • Adds a Factory as the last view controller in the stack.

    Declaration

    Swift

    public final func with<ChildFC, T>(_ childFactory: ChildFC, adapting transformer: T) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context> where ChildFC : Factory, T : ContextTransformer, FC.Context == T.SourceContext, ChildFC.Context == T.TargetContext

    Parameters

    childFactory

    The instance of Factory.

    transformer

    The instance of ContextTransformer to use to adapt parent ContainerFactory Context.

  • Adds a ContainerFactory as the last view controller in the stack.

    Declaration

    Swift

    public final func with<ChildFC, T>(_ childContainer: ChildFC, adapting transformer: T) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context> where ChildFC : ContainerFactory, T : ContextTransformer, FC.Context == T.SourceContext, ChildFC.Context == T.TargetContext

    Parameters

    childContainer

    The instance of ContainerFactory.

    transformer

    The instance of ContextTransformer to use to adapt parent ContainerFactory Context.

  • Adds a Factory that is going to be used as a child

    Declaration

    Swift

    public final func with<ChildFC: Factory, A: ContainerAction>(_ childFactory: ChildFC, using action: A) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context>
        where
        ChildFC.Context == FC.Context, A.ViewController == FC.ViewController

    Parameters

    childFactory

    The instance of Factory.

    action

    The instance of Factory to be used to integrate the view controller produced by the factory.

  • Adds a ContainerFactory that is going to be used as a child

    Declaration

    Swift

    public final func with<ChildFC: ContainerFactory, A: ContainerAction>(_ childContainer: ChildFC, using action: A) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context>
        where
        ChildFC.Context == FC.Context, A.ViewController == FC.ViewController

    Parameters

    childContainer

    The instance of ContainerFactory.

    action

    The instance of ContainerFactory to be used to integrate the view controller produced by the factory.

  • Adds a Factory as the last view controller in the stack.

    Declaration

    Swift

    public final func with<ChildFC>(_ childFactory: ChildFC) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context> where ChildFC : Factory, FC.Context == ChildFC.Context

    Parameters

    childFactory

    The instance of Factory.

  • Adds a ContainerFactory as the last view controller in the stack.

    Declaration

    Swift

    public final func with<ChildFC>(_ childContainer: ChildFC) -> CompleteFactoryChainAssembly<FC, ChildFC.ViewController, ChildFC.Context> where ChildFC : ContainerFactory, FC.Context == ChildFC.Context

    Parameters

    childContainer

    The instance of ContainerFactory.

  • Applies a ContextTask to the child factory after its UIViewController been built.

    Declaration

    Swift

    public final func adding<CT>(_ contextTask: CT) -> CompleteFactoryChainAssembly<FC, ChildVC, ChildContext> where ChildVC == CT.ViewController, ChildContext == CT.Context, CT : ContextTask

    Parameters

    contextTask

    The instance of ContextTask.

  • Assembles all the children factories provided and returns a ContainerFactory instance.

    Declaration

    Swift

    public final func assemble() -> CompleteFactory<FC>

    Return Value

    The CompleteFactory with child factories provided.