Class: FeatureFlagger::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/feature_flagger/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



5
6
7
8
# File 'lib/feature_flagger/configuration.rb', line 5

def initialize
  @storage       ||= Storage::Redis.default_client
  @yaml_filepath ||= default_yaml_filepath
end

Instance Attribute Details

#storageObject

Returns the value of attribute storage.



3
4
5
# File 'lib/feature_flagger/configuration.rb', line 3

def storage
  @storage
end

#yaml_filepathObject

Returns the value of attribute yaml_filepath.



3
4
5
# File 'lib/feature_flagger/configuration.rb', line 3

def yaml_filepath
  @yaml_filepath
end

Instance Method Details

#infoObject



10
11
12
# File 'lib/feature_flagger/configuration.rb', line 10

def info
  @info ||= YAML.load_file(yaml_filepath) if yaml_filepath
end