class AMQP::Client::Connection

Defined in:

amqp-client/connection.cr
amqp-client/errors.cr

Class Method Summary

Instance Method Summary

Class Method Detail

def self.start(io : UNIXSocket | TCPSocket | OpenSSL::SSL::Socket::Client | WebSocketIO, user, password, vhost, channel_max, frame_max, heartbeat, name = File.basename(PROGRAM_NAME)) #

Connection negotiation


[View source]

Instance Method Detail

def channel(id : Int | Nil = nil) #

Opens a channel


[View source]
def channel(& : Channel -> _) #

[View source]
def channel_max : UInt16 #

[View source]
def close(reason = "", no_wait = false) #

Close the connection the server.

The reason might be logged by the server


[View source]
def closed? : Bool #

[View source]
def closing_frame : Frame::Connection::Close | Nil #

[View source]
def frame_max : UInt32 #

[View source]
def on_close(&blk : UInt16, String -> ) #

Callback that's called if the Connection is closed by the server


[View source]