Class: CoBreak::Binary
- Inherits:
-
Object
- Object
- CoBreak::Binary
- Defined in:
- lib/cobreak/binary.rb
Class Method Summary collapse
Class Method Details
.binary(dato) ⇒ Object
3 4 5 |
# File 'lib/cobreak/binary.rb', line 3 def self.binary(dato) return dato.unpack("B*").join('') end |
.hexbinary(dato) ⇒ Object
6 7 8 |
# File 'lib/cobreak/binary.rb', line 6 def self.hexbinary(dato) return [dato].pack("B*") end |