Class: ConfigurationService::Configuration
- Inherits:
-
Object
- Object
- ConfigurationService::Configuration
- Defined in:
- lib/configuration_service/configuration.rb
Overview
Encapsulates configuration data and its metadata
-
+identifier is the string identifier of the data and metadata.
-
datais a dictionary of (possibly sensitive) configuration data, which providers are expected to secure. -
metadatais a dictionary of data about the configuration data, which providers are not expected to secure.
It is recommended that both dictionaries use strings as keys, and that values be limited to those that can be serialized to JSON.
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
TODO consider removing :revision as an attr.
-
#identifier ⇒ Object
readonly
TODO consider removing :revision as an attr.
-
#metadata ⇒ Object
readonly
TODO consider removing :revision as an attr.
-
#revision ⇒ Object
readonly
TODO consider removing :revision as an attr.
Instance Method Summary collapse
-
#initialize(identifier, data, metadata) ⇒ Configuration
constructor
Returns a new Configuration.
Constructor Details
#initialize(identifier, data, metadata) ⇒ Configuration
Returns a new Configuration
23 24 25 26 27 28 |
# File 'lib/configuration_service/configuration.rb', line 23 def initialize(identifier, data, ) @identifier = identifier @data = data @metadata = @revision = ["revision"] end |
Instance Attribute Details
#data ⇒ Object (readonly)
TODO consider removing :revision as an attr
18 19 20 |
# File 'lib/configuration_service/configuration.rb', line 18 def data @data end |
#identifier ⇒ Object (readonly)
TODO consider removing :revision as an attr
18 19 20 |
# File 'lib/configuration_service/configuration.rb', line 18 def identifier @identifier end |
#metadata ⇒ Object (readonly)
TODO consider removing :revision as an attr
18 19 20 |
# File 'lib/configuration_service/configuration.rb', line 18 def @metadata end |
#revision ⇒ Object (readonly)
TODO consider removing :revision as an attr
18 19 20 |
# File 'lib/configuration_service/configuration.rb', line 18 def revision @revision end |