Class: Umbra::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/umbra/config.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#encoderObject

Returns the value of attribute encoder.



3
4
5
# File 'lib/umbra/config.rb', line 3

def encoder
  @encoder
end

#error_handlerObject

Returns the value of attribute error_handler.



3
4
5
# File 'lib/umbra/config.rb', line 3

def error_handler
  @error_handler
end

#loggerObject

Returns the value of attribute logger.



3
4
5
# File 'lib/umbra/config.rb', line 3

def logger
  @logger
end

#publisherObject

Returns the value of attribute publisher.



3
4
5
# File 'lib/umbra/config.rb', line 3

def publisher
  @publisher
end

#redis_optionsObject

Returns the value of attribute redis_options.



3
4
5
# File 'lib/umbra/config.rb', line 3

def redis_options
  @redis_options
end

#request_selectorObject

Returns the value of attribute request_selector.



3
4
5
# File 'lib/umbra/config.rb', line 3

def request_selector
  @request_selector
end

Class Method Details

.default(&block) ⇒ Object



5
6
7
8
9
10
11
12
13
14
15
# File 'lib/umbra/config.rb', line 5

def self.default(&block)
  new(
    publisher: Publisher.new,
    request_selector: RequestSelector,
    encoder: Encoder,
    error_handler: SuppressErrorHandler,
    redis_options: {},
    logger: Logger.new($stdout),
    &block
  )
end