Class: HammerCLIKatello::HostBootc::ImagesCommand

Inherits:
ListCommand
  • Object
show all
Defined in:
lib/hammer_cli_katello/host_bootc.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from ListCommand

build_options

Methods included from ResolverCommons

included

Class Method Details

.parse_data(data_collection) ⇒ Object



20
21
22
23
24
25
26
27
# File 'lib/hammer_cli_katello/host_bootc.rb', line 20

def self.parse_data(data_collection)
  data = data_collection.inject([]) do |list, item|
    list + item["digests"].collect do |digest|
      digest.merge(:bootc_booted_image => item["bootc_booted_image"])
    end
  end
  HammerCLI::Output::RecordCollection.new(data, :meta => data_collection.meta)
end

Instance Method Details

#send_requestObject



16
17
18
# File 'lib/hammer_cli_katello/host_bootc.rb', line 16

def send_request
  self.class.parse_data(super)
end