Module: EOAT::Cache

Defined in:
lib/eoat/cache/none_cache.rb,
lib/eoat/cache/file_cache.rb,
lib/eoat/cache/redis_cache.rb,
lib/eoat/cache/memcached_cache.rb

Overview

Collection of EOAT cache handlers All handlers have a public methods: #get and #save

Author:

Defined Under Namespace

Classes: FileCache, MemcachedCache, NoneCache, RedisCache

Class Method Summary collapse

Class Method Details

.md5hash(string) ⇒ String

Module method. Calculating md5 of string. Used by all cached handlers.

Parameters:

  • string (String)

Returns:

  • (String)

    the md5 hash string



30
31
32
33
34
# File 'lib/eoat/cache/none_cache.rb', line 30

def self.md5hash(string)
  require 'digest/md5'

  return Digest::MD5.hexdigest(string.to_s)
end