module RbNaCl::Serializable

Serialization features shared across all “key-like” classes

Public Instance Methods

inspect() click to toggle source

Inspect this key

@return [String] a string representing this key

# File lib/rbnacl/serializable.rb, line 18
def inspect
  "#<#{self.class}:#{Util.bin2hex(to_bytes)[0, 8]}>"
end
to_s() click to toggle source
# File lib/rbnacl/serializable.rb, line 7
def to_s
  to_bytes
end
to_str() click to toggle source
# File lib/rbnacl/serializable.rb, line 11
def to_str
  to_bytes
end