Class: AMQ::Protocol::Float32Bit

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

Overview

Allows distinguishing between 32-bit and 64-bit floats in Ruby. Useful in cases when RabbitMQ plugins encode values as 32 bit numbers.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value) ⇒ Float32Bit

Returns a new instance of Float32Bit.



9
10
11
# File 'lib/amq/protocol/float_32bit.rb', line 9

def initialize(value)
  @value = value
end

Instance Attribute Details

#valueObject (readonly)

Returns the value of attribute value.



7
8
9
# File 'lib/amq/protocol/float_32bit.rb', line 7

def value
  @value
end