Class: Moneta::Transforms::City64
- Inherits:
-
Moneta::Transform
- Object
- Moneta::Transform
- Moneta::Transforms::City64
- Defined in:
- lib/moneta/transforms/city64.rb
Overview
Hashes strings using the cityhash gem - 64 bit version
Instance Method Summary collapse
-
#encode(value) ⇒ String
Hashes using the
CityHash64
algorithm.
Methods inherited from Moneta::Transform
#decodable?, #decode, delegate_to, #initialize, #method_missing, #respond_to_missing?
Constructor Details
This class inherits a constructor from Moneta::Transform
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Moneta::Transform
Instance Method Details
#encode(value) ⇒ String
Hashes using the CityHash64
algorithm
11 12 13 |
# File 'lib/moneta/transforms/city64.rb', line 11 def encode(value) ::CityHash.hash64(value).to_s(16) end |