Class: Backup::Logger::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/backup/logger.rb

Defined Under Namespace

Classes: DSL, Logger

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig

Returns a new instance of Config.



23
24
25
26
27
28
29
30
31
# File 'lib/backup/logger.rb', line 23

def initialize
  @ignores = []
  @loggers = [
    Logger.new(Console, Console::Options.new),
    Logger.new(Logfile, Logfile::Options.new),
    Logger.new(Syslog, Syslog::Options.new)
  ]
  @dsl = DSL.new(ignores, *loggers.map(&:options))
end

Instance Attribute Details

#dslObject (readonly)

Returns the value of attribute dsl.



21
22
23
# File 'lib/backup/logger.rb', line 21

def dsl
  @dsl
end

#ignoresObject (readonly)

Returns the value of attribute ignores.



21
22
23
# File 'lib/backup/logger.rb', line 21

def ignores
  @ignores
end

#loggersObject (readonly)

Returns the value of attribute loggers.



21
22
23
# File 'lib/backup/logger.rb', line 21

def loggers
  @loggers
end