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.



26
27
28
29
30
31
32
33
34
# File 'lib/backup/logger.rb', line 26

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.



24
25
26
# File 'lib/backup/logger.rb', line 24

def dsl
  @dsl
end

#ignoresObject (readonly)

Returns the value of attribute ignores.



24
25
26
# File 'lib/backup/logger.rb', line 24

def ignores
  @ignores
end

#loggersObject (readonly)

Returns the value of attribute loggers.



24
25
26
# File 'lib/backup/logger.rb', line 24

def loggers
  @loggers
end