Class: AMQ::Protocol::Connection::StartOk

Inherits:
Method
  • Object
show all
Defined in:
lib/amq/protocol/client.rb

Class Method Summary collapse

Methods inherited from Method

encode_body, index, inherited, instantiate, method_id, methods, name, split_headers

Class Method Details

.encode(client_properties, mechanism, response, locale) ⇒ Object

u’client_properties = nil’, u“mechanism = u’PLAIN’”, u’response = nil’, u“locale = u’en_US’”

Returns:



353
354
355
356
357
358
359
360
361
362
363
364
365
# File 'lib/amq/protocol/client.rb', line 353

def self.encode(client_properties, mechanism, response, locale)
  channel = 0
  buffer = ''
  buffer << @packed_indexes
  buffer << AMQ::Protocol::Table.encode(client_properties)
  buffer << mechanism.to_s.bytesize.chr
  buffer << mechanism.to_s
  buffer << [response.to_s.bytesize].pack(PACK_UINT32)
  buffer << response.to_s
  buffer << locale.to_s.bytesize.chr
  buffer << locale.to_s
  MethodFrame.new(buffer, channel)
end

.has_content?Boolean

Returns:

  • (Boolean)


347
348
349
# File 'lib/amq/protocol/client.rb', line 347

def self.has_content?
  false
end