Class: SNMP::Integer32
Instance Method Summary collapse
-
#initialize(value) ⇒ Integer32
constructor
A new instance of Integer32.
Methods inherited from Integer
#<=>, #asn1_type, #coerce, decode, #encode, #to_f, #to_i, #to_s
Constructor Details
#initialize(value) ⇒ Integer32
Returns a new instance of Integer32.
99 100 101 102 103 |
# File 'lib/snmp/varbind.rb', line 99 def initialize(value) super(value) raise ArgumentError, "Out of range: #{value}" if value < -2147483648 raise ArgumentError, "Out of range: #{value}" if value > 2147483647 end |