Class: Lit::Loader

Inherits:
Object
  • Object
show all
Defined in:
lib/lit/loader.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeLoader

Returns a new instance of Loader.



9
10
11
12
13
14
# File 'lib/lit/loader.rb', line 9

def initialize
  self.logger ||= Logger.new($stdout)
  self.logger.info 'initializing Lit'
  self.cache ||= Cache.new
  I18n.backend = I18nBackend.new(self.cache)
end

Instance Attribute Details

#cacheObject

Returns the value of attribute cache.



7
8
9
# File 'lib/lit/loader.rb', line 7

def cache
  @cache
end

#loggerObject

Returns the value of attribute logger.



8
9
10
# File 'lib/lit/loader.rb', line 8

def logger
  @logger
end