Table of Contents

Class InMemoryMessageChannel

Namespace
StockSharp.Messages
Assembly
StockSharp.Messages.dll

Message channel, based on the queue and operate within a single process.

public class InMemoryMessageChannel : Disposable, IMessageChannel, IMessageTransport, IDisposable, ICloneable<IMessageChannel>, ICloneable
Inheritance
InMemoryMessageChannel
Implements
Inherited Members
Extension Methods

Constructors

InMemoryMessageChannel(IMessageQueue, string, Action<Exception>)

Initializes a new instance of the InMemoryMessageChannel.

public InMemoryMessageChannel(IMessageQueue queue, string name, Action<Exception> errorHandler)

Parameters

queue IMessageQueue

Message queue.

name string

Channel name.

errorHandler Action<Exception>

Error handler.

Properties

Disabled

The channel cannot be opened.

public bool Disabled { get; set; }

Property Value

bool

MessageCount

Message queue count.

public int MessageCount { get; }

Property Value

int

Name

Handler name.

public string Name { get; }

Property Value

string

State

State.

public ChannelStates State { get; }

Property Value

ChannelStates

Methods

Clone()

Creates a new object that is a deep copy of the current instance.

public virtual IMessageChannel Clone()

Returns

IMessageChannel

A new object that is a deep copy of this instance.

Close()

Close channel.

public void Close()

DisposeManaged()

Disposes the managed resources. Override this method to add custom clean up of managed resources.

protected override void DisposeManaged()

Open()

Open channel.

public void Open()

Events

NewOutMessageAsync

New message event.

public event Func<Message, CancellationToken, ValueTask> NewOutMessageAsync

Event Type

Func<Message, CancellationToken, ValueTask>

StateChanged

State change event.

public event Action StateChanged

Event Type

Action