Class: Array

Inherits:
Object
  • Object
show all
Defined in:
lib/rublicatorg.rb

Instance Method Summary collapse

Instance Method Details

#hex_to_strObject



27
28
29
30
31
# File 'lib/rublicatorg.rb', line 27

def hex_to_str
  str = ""
  self.collect{|b| str << "%c" % b}
  str
end

#to_hex_strObject



33
34
35
# File 'lib/rublicatorg.rb', line 33

def to_hex_str
  self.collect{|e| "0x%02x" % e}.join(" ")
end