Table of Contents

Class SimpleConnection

Namespace
Steeltoe.Messaging.RabbitMQ.Connection
Assembly
Steeltoe.Messaging.RabbitMQ.dll
public class SimpleConnection : IConnection, IDisposable, NetworkConnection
Inheritance
SimpleConnection
Implements
NetworkConnection
Inherited Members

Constructors

SimpleConnection(IConnection, int, ILogger)

public SimpleConnection(IConnection connection, int closeTimeout, ILogger logger = null)

Parameters

connection IConnection
closeTimeout int
logger ILogger

Properties

Address

public string Address { get; }

Property Value

string

Connection

Gets the underlying RabbitMQ connection

public IConnection Connection { get; }

Property Value

IConnection

IsOpen

Gets a value indicating whether the connection is open

public bool IsOpen { get; }

Property Value

bool

LocalPort

Gets the local port of the connection

public int LocalPort { get; }

Property Value

int

Port

public int Port { get; }

Property Value

int

RemotePort

Remote port.

public int RemotePort { get; }

Property Value

int

Methods

AddBlockedListener(IBlockedListener)

Add a Blocked listener to the connection

public void AddBlockedListener(IBlockedListener listener)

Parameters

listener IBlockedListener

the listener to add

Close()

Close the connection

public void Close()

CreateChannel(bool)

Create a new channel, using an inernally allocated channel number

public IModel CreateChannel(bool transactional = false)

Parameters

transactional bool

true if transaction support on channel

Returns

IModel

the new channel

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()

RemoveBlockedListener(IBlockedListener)

Remove a Blocked listener from the connection

public bool RemoveBlockedListener(IBlockedListener listener)

Parameters

listener IBlockedListener

the listener to remove

Returns

bool

true if successful