Class ProducerPipelineContext<TState>
The context that is passed along the producer behaviors pipeline.
Inherited Members
Namespace: Silverback.Messaging.Broker.Behaviors
Assembly: Silverback.Integration.dll
Syntax
public class ProducerPipelineContext<TState> : ProducerPipelineContext
Type Parameters
| Name | Description |
|---|---|
| TState |
Constructors
ProducerPipelineContext(IOutboundEnvelope, IProducer, IReadOnlyList<IProducerBehavior>, ProducerBehaviorHandler, IServiceProvider)
Initializes a new instance of the ProducerPipelineContext<TState> class.
Declaration
public ProducerPipelineContext(IOutboundEnvelope envelope, IProducer producer, IReadOnlyList<IProducerBehavior> pipeline, ProducerBehaviorHandler finalAction, IServiceProvider serviceProvider)
Parameters
| Type | Name | Description |
|---|---|---|
| IOutboundEnvelope | envelope | The envelope containing the message to be produced. |
| IProducer | producer | The IProducer that triggered this pipeline. |
| IReadOnlyList<IProducerBehavior> | pipeline | The behaviors composing the pipeline. |
| ProducerBehaviorHandler | finalAction | The final action to be executed after the pipeline has been processed. |
| IServiceProvider | serviceProvider | The IServiceProvider to be used to resolve the required services. |
Methods
Clone(IOutboundEnvelope?)
Clones the current context, optionally replacing the envelope.
Declaration
public override ProducerPipelineContext Clone(IOutboundEnvelope? newEnvelope = null)
Parameters
| Type | Name | Description |
|---|---|---|
| IOutboundEnvelope | newEnvelope | The new envelope to be used in the cloned context. |
Returns
| Type | Description |
|---|---|
| ProducerPipelineContext | The cloned context. |