Class: Datadog::Core::Remote::Configuration::Repository::Operation::Set

Inherits:
Object
  • Object
show all
Defined in:
lib/datadog/core/remote/configuration/repository.rb

Overview

Set repository metadata

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**options) ⇒ Set

Returns a new instance of Set.



213
214
215
216
217
# File 'lib/datadog/core/remote/configuration/repository.rb', line 213

def initialize(**options)
  super()
  @opaque_backend_state = options[:opaque_backend_state]
  @targets_version = options[:targets_version]
end

Instance Attribute Details

#opaque_backend_stateObject (readonly)

Returns the value of attribute opaque_backend_state.



211
212
213
# File 'lib/datadog/core/remote/configuration/repository.rb', line 211

def opaque_backend_state
  @opaque_backend_state
end

#targets_versionObject (readonly)

Returns the value of attribute targets_version.



211
212
213
# File 'lib/datadog/core/remote/configuration/repository.rb', line 211

def targets_version
  @targets_version
end

Instance Method Details

#apply(repository) ⇒ Object



219
220
221
222
223
224
225
# File 'lib/datadog/core/remote/configuration/repository.rb', line 219

def apply(repository)
  repository.instance_variable_set(:@opaque_backend_state, @opaque_backend_state) if @opaque_backend_state

  repository.instance_variable_set(:@targets_version, @targets_version) if @targets_version

  nil
end