Class: Hcloud::ResourceLoader

Inherits:
Object
  • Object
show all
Defined in:
lib/hcloud/resource_loader.rb

Instance Method Summary collapse

Constructor Details

#initialize(schema, client:) ⇒ ResourceLoader

Returns a new instance of ResourceLoader.



7
8
9
10
# File 'lib/hcloud/resource_loader.rb', line 7

def initialize(schema, client:)
  @schema = schema
  @client = client
end

Instance Method Details

#load(data) ⇒ Object



12
13
14
# File 'lib/hcloud/resource_loader.rb', line 12

def load(data)
  load_with_schema(@schema, data)
end