ActionDispatcher

public protocol ActionDispatcher

An object that dispatches actions to a store.

Once an action is sent, the sender shouldn’t expect anything to occur. Instead, it should rely solely on changes to the state of the application to respond.

  • Sends an action to a reducer to mutate the state of the application.

    Declaration

    Swift

    func send(_ action: Action)

    Parameters

    action

    An action to dispatch to the store.

  • Create a new ActionDispatcher that acts as a proxy for the current one.

    Actions can be modified by both the new proxy and the original dispatcher it was created from.

    Declaration

    Swift

    func proxy(modifyAction: ActionModifier?, sentAction: ((Action) -> Void)?) -> ActionDispatcher

    Return Value

    a new action dispatcher.

  • receive(_:) Extension method

    Undocumented

    Declaration

    Swift

    public func receive(_ input: Action) -> Subscribers.Demand
  • receive(completion:) Extension method

    Undocumented

    Declaration

    Swift

    public func receive(completion: Subscribers.Completion<Never>)
  • receive(subscription:) Extension method

    Undocumented

    Declaration

    Swift

    public func receive(subscription: Subscription)