Class: Datadog::Core::Remote::Configuration::Repository::State
- Inherits:
-
Object
- Object
- Datadog::Core::Remote::Configuration::Repository::State
- Defined in:
- lib/datadog/core/remote/configuration/repository.rb
Overview
State store the repository state
Instance Attribute Summary collapse
-
#cached_target_files ⇒ Object
readonly
Returns the value of attribute cached_target_files.
-
#config_states ⇒ Object
readonly
Returns the value of attribute config_states.
-
#error ⇒ Object
readonly
Returns the value of attribute error.
-
#has_error ⇒ Object
readonly
Returns the value of attribute has_error.
-
#opaque_backend_state ⇒ Object
readonly
Returns the value of attribute opaque_backend_state.
-
#root_version ⇒ Object
readonly
Returns the value of attribute root_version.
-
#targets_version ⇒ Object
readonly
Returns the value of attribute targets_version.
Instance Method Summary collapse
-
#initialize(repository) ⇒ State
constructor
A new instance of State.
Constructor Details
#initialize(repository) ⇒ State
Returns a new instance of State.
77 78 79 80 81 82 83 84 85 86 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 77 def initialize(repository) @repository = repository @root_version = repository.root_version @targets_version = repository.targets_version @config_states = contents_to_config_states(repository.contents) @has_error = false @error = '' @opaque_backend_state = repository.opaque_backend_state @cached_target_files = contents_to_cached_target_files(repository.contents) end |
Instance Attribute Details
#cached_target_files ⇒ Object (readonly)
Returns the value of attribute cached_target_files.
68 69 70 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 68 def cached_target_files @cached_target_files end |
#config_states ⇒ Object (readonly)
Returns the value of attribute config_states.
68 69 70 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 68 def config_states @config_states end |
#error ⇒ Object (readonly)
Returns the value of attribute error.
68 69 70 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 68 def error @error end |
#has_error ⇒ Object (readonly)
Returns the value of attribute has_error.
68 69 70 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 68 def has_error @has_error end |
#opaque_backend_state ⇒ Object (readonly)
Returns the value of attribute opaque_backend_state.
68 69 70 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 68 def opaque_backend_state @opaque_backend_state end |
#root_version ⇒ Object (readonly)
Returns the value of attribute root_version.
68 69 70 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 68 def root_version @root_version end |
#targets_version ⇒ Object (readonly)
Returns the value of attribute targets_version.
68 69 70 |
# File 'lib/datadog/core/remote/configuration/repository.rb', line 68 def targets_version @targets_version end |