public final class

ChannelManager

extends Object
java.lang.Object
   ↳ com.rabbitmq.client.impl.ChannelManager

Class Overview

Manages a set of channels, indexed by channel number (1.._channelMax).

Summary

Public Constructors
ChannelManager(ConsumerWorkService workService, int channelMax)
Public Methods
ChannelN createChannel(AMQConnection connection)
ChannelN createChannel(AMQConnection connection, int channelNumber)
ChannelN getChannel(int channelNumber)
Looks up a channel on this connection.
int getChannelMax()
void handleSignal(ShutdownSignalException signal)
void releaseChannelNumber(ChannelN channel)
Remove the channel from the channel map and free the number for re-use.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public ChannelManager (ConsumerWorkService workService, int channelMax)

Public Methods

public ChannelN createChannel (AMQConnection connection)

Throws
IOException

public ChannelN createChannel (AMQConnection connection, int channelNumber)

Throws
IOException

public ChannelN getChannel (int channelNumber)

Looks up a channel on this connection.

Parameters
channelNumber the number of the required channel
Returns
  • the channel on this connection with number channelNumber
Throws
if there is no channel with number channelNumber on this connection

public int getChannelMax ()

public void handleSignal (ShutdownSignalException signal)

public void releaseChannelNumber (ChannelN channel)

Remove the channel from the channel map and free the number for re-use. This method must be safe to call multiple times on the same channel. If it is not then things go badly wrong.