module EasyRedis::Methods

Public Class Methods

included(klass) click to toggle source
# File lib/easy_redis/methods/methods.rb, line 9
def self.included(klass)
  klass.class_eval do
    include EasyRedis::Getters
    include EasyRedis::Setters
    include EasyRedis::Deleters
  end
end

Public Instance Methods

redis_cli() click to toggle source
# File lib/easy_redis/methods/methods.rb, line 22
def redis_cli
  EasyRedis::Redis.redis
end
redis_key() click to toggle source
# File lib/easy_redis/methods/methods.rb, line 17
def redis_key
  raise NonExistentObjectError if self.new_record? && EasyRedis::Redis.raise_non_existent_object_error?
  @redis_key ||= "#{EasyRedis::Redis.namespace}:attributes:#{self.class.name}:#{self.id}"
end