Exception: CBOR::OutOfBytesError
- Defined in:
- lib/cbor-pure.rb
Instance Attribute Summary collapse
-
#bytes ⇒ Object
readonly
Returns the value of attribute bytes.
Instance Method Summary collapse
-
#initialize(bytes) ⇒ OutOfBytesError
constructor
A new instance of OutOfBytesError.
- #to_s ⇒ Object
Constructor Details
#initialize(bytes) ⇒ OutOfBytesError
Returns a new instance of OutOfBytesError.
8 9 10 |
# File 'lib/cbor-pure.rb', line 8 def initialize(bytes) @bytes = bytes end |
Instance Attribute Details
#bytes ⇒ Object (readonly)
Returns the value of attribute bytes.
15 16 17 |
# File 'lib/cbor-pure.rb', line 15 def bytes @bytes end |
Instance Method Details
#to_s ⇒ Object
12 13 14 |
# File 'lib/cbor-pure.rb', line 12 def to_s "Out of bytes to decode (need at least #{@bytes} byte#{bytes == 1 ? "" : "s"} more)" end |