Class: Moose::Inventory::Operations::InventorySnapshotApplier

Inherits:
Object
  • Object
show all
Defined in:
lib/moose_inventory/operations/inventory_snapshot_applier.rb

Overview

Applies an already-validated inventory snapshot to the current inventory.

Defined Under Namespace

Classes: Result

Instance Method Summary collapse

Constructor Details

#initialize(context:) ⇒ InventorySnapshotApplier

Returns a new instance of InventorySnapshotApplier.



10
11
12
# File 'lib/moose_inventory/operations/inventory_snapshot_applier.rb', line 10

def initialize(context:)
  @context = context
end

Instance Method Details

#call(snapshot:) ⇒ Object



14
15
16
# File 'lib/moose_inventory/operations/inventory_snapshot_applier.rb', line 14

def call(snapshot:)
  apply_snapshot(snapshot)
end