module HashIdentable::HshFunction

Public Class Methods

decode(item) click to toggle source
# File lib/hash_identable/hsh_function.rb, line 14
def self.decode item
  hashing_object.decode item
end
encode(key) click to toggle source
# File lib/hash_identable/hsh_function.rb, line 10
def self.encode key
  hashing_object.encode key
end
hashing_object() click to toggle source
# File lib/hash_identable/hsh_function.rb, line 6
def self.hashing_object
  @hashing_object ||= Hashids.new(salt, hash_length)
end

Private Class Methods

hash_length() click to toggle source
# File lib/hash_identable/hsh_function.rb, line 23
def self.hash_length
  @hash_length ||= HashIdentable.configuration.hash_length
end
salt() click to toggle source
# File lib/hash_identable/hsh_function.rb, line 19
def self.salt
  @salt ||= HashIdentable.configuration.salt
end