STRUCT
StateMutationSink¶
public struct StateMutationSink<WorkflowType: Workflow>
StateMutationSink provides a Sink that helps mutate State using it’s KeyPath.
Methods¶
send(_:)¶
public func send(_ update: @escaping (inout WorkflowType.State) -> Void)
Sends message to StateMutationSink to update State’s value using the provided closure.
- Parameters:
 - update: The 
Statemutation to perform. 
Parameters¶
| Name | Description | 
|---|---|
| update | The State mutation to perform. | 
send(_:value:)¶
public func send<Value>(_ keyPath: WritableKeyPath<WorkflowType.State, Value>, value: Value)
Sends message to StateMutationSink to update State’s value at KeyPath with Value.
- Parameters:
 - keyPath: Key path of 
Statewhose value needs to be mutated. - value: Value to update 
Statewith. 
Parameters¶
| Name | Description | 
|---|---|
| keyPath | Key path of State whose value needs to be mutated. | 
| value | Value to update State with. |