Module: Zmeygo

Defined in:
lib/zmeygo/base.rb,
lib/zmeygo/cache.rb,
lib/zmeygo/client.rb,
lib/zmeygo/command.rb,
lib/zmeygo/version.rb,
lib/zmeygo/constant.rb,
lib/zmeygo/i18n_backend.rb,
lib/zmeygo/configuration.rb

Defined Under Namespace

Classes: Cache, Client, Command, Configuration, Constant, I18nBackend

Constant Summary collapse

VERSION =
"0.1"

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.cacheObject

Returns the value of attribute cache.



22
23
24
# File 'lib/zmeygo/base.rb', line 22

def cache
  @cache
end

.clientObject

Returns the value of attribute client.



20
21
22
# File 'lib/zmeygo/base.rb', line 20

def client
  @client
end

.configObject

Returns the value of attribute config.



21
22
23
# File 'lib/zmeygo/base.rb', line 21

def config
  @config
end

.loggerObject

Returns the value of attribute logger.



23
24
25
# File 'lib/zmeygo/base.rb', line 23

def logger
  @logger
end

Class Method Details

.configureObject



29
30
31
32
33
34
35
36
# File 'lib/zmeygo/base.rb', line 29

def configure
  self.config ||= Configuration.new
  if block_given?
    yield(config)
  end
  self.cache = Cache.new
  self.logger = Logger.new($stdout)
end

.method_missing(method, *args) ⇒ Object



25
26
27
# File 'lib/zmeygo/base.rb', line 25

def method_missing(method, *args)
  self.cache.respond_to?(method)? cache.send(method, *args) : super
end