module RedisDataViewer

Constants

VERSION

Public Class Methods

redis_client() click to toggle source
# File lib/redis_data_viewer.rb, line 19
def self.redis_client
  if setup_data.use_password
    @client ||= Redis.new(host: setup_data.redis_host, port: setup_data.redis_port, password: setup_data.redis_password || '')
  else
    @client ||= Redis.new(host: setup_data.redis_host, port: setup_data.redis_port)
  end
end
setup() { |setup_data| ... } click to toggle source
# File lib/redis_data_viewer.rb, line 15
def self.setup
  yield(self.setup_data)
end
setup_data() click to toggle source

Your code goes here… class << self

attr_accessor :config

end

# File lib/redis_data_viewer.rb, line 11
def self.setup_data
  @setup_data ||= Configuration.new
end