Show / Hide Table of Contents

    Class EnvelopeFactory

    Can be used to instantiate an IOutboundEnvelope or an IInboundEnvelope.

    Inheritance
    object
    EnvelopeFactory
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Silverback.Messaging.Messages
    Assembly: Silverback.Integration.dll
    Syntax
    public static class EnvelopeFactory

    Methods

    | Improve this doc View source

    Create(byte[]?, MessageHeaderCollection?, IConsumerEndpoint, IBrokerMessageIdentifier)

    Creates an IRawInboundEnvelope.

    Declaration
    public static IRawInboundEnvelope Create(byte[]? rawMessage, MessageHeaderCollection? headers, IConsumerEndpoint endpoint, IBrokerMessageIdentifier identifier)
    Parameters
    Type Name Description
    byte[] rawMessage

    The raw message body.

    MessageHeaderCollection headers

    The message headers.

    IConsumerEndpoint endpoint

    The source endpoint.

    IBrokerMessageIdentifier identifier

    The IBrokerMessageIdentifier.

    Returns
    Type Description
    IRawInboundEnvelope

    An IInboundEnvelope<TMessage> containing the specified message.

    | Improve this doc View source

    Create(Stream, MessageHeaderCollection?, IConsumerEndpoint, IBrokerMessageIdentifier)

    Creates an IRawInboundEnvelope.

    Declaration
    public static IRawInboundEnvelope Create(Stream rawMessageStream, MessageHeaderCollection? headers, IConsumerEndpoint endpoint, IBrokerMessageIdentifier identifier)
    Parameters
    Type Name Description
    Stream rawMessageStream

    The raw message body.

    MessageHeaderCollection headers

    The message headers.

    IConsumerEndpoint endpoint

    The source endpoint.

    IBrokerMessageIdentifier identifier

    The IBrokerMessageIdentifier.

    Returns
    Type Description
    IRawInboundEnvelope

    An IInboundEnvelope<TMessage> containing the specified message.

    | Improve this doc View source

    Create<TMessage>(TMessage, IRawInboundEnvelope)

    Creates an IInboundEnvelope<TMessage> copying another envelope and replacing just the deserialized message.

    Declaration
    public static IInboundEnvelope<TMessage> Create<TMessage>(TMessage message, IRawInboundEnvelope rawInboundEnvelope) where TMessage : class
    Parameters
    Type Name Description
    TMessage message

    The message to be wrapped in the envelope.

    IRawInboundEnvelope rawInboundEnvelope

    The envelope to be copied.

    Returns
    Type Description
    IInboundEnvelope<TMessage>

    An IInboundEnvelope<TMessage> containing the specified message.

    Type Parameters
    Name Description
    TMessage

    The type of the message being wrapped.

    | Improve this doc View source

    Create<TMessage>(TMessage, MessageHeaderCollection?, IProducerEndpoint)

    Creates an IOutboundEnvelope<TMessage>.

    Declaration
    public static IOutboundEnvelope<TMessage> Create<TMessage>(TMessage message, MessageHeaderCollection? headers, IProducerEndpoint endpoint) where TMessage : class
    Parameters
    Type Name Description
    TMessage message

    The message to be wrapped in the envelope.

    MessageHeaderCollection headers

    The message headers.

    IProducerEndpoint endpoint

    The destination endpoint.

    Returns
    Type Description
    IOutboundEnvelope<TMessage>

    An IOutboundEnvelope<TMessage> containing the specified message.

    Type Parameters
    Name Description
    TMessage

    The type of the message being wrapped.

    • Improve this doc
    • View source
    GitHub E-Mail
    ↑ Back to top © 2020 Sergio Aquilini