Class: HammerCLIForeman::InfoCommand
Direct Known Subclasses
Architecture::InfoCommand, Audit::InfoCommand, AuthSourceExternal::InfoCommand, AuthSourceLdap::InfoCommand, Combination::InfoCombination, ComputeProfile::InfoCommand, ComputeResource::InfoCommand, ConfigGroup::InfoCommand, ConfigReport::InfoCommand, Domain::InfoCommand, ExternalUsergroup::InfoCommand, Filter::InfoCommand, Host::InfoCommand, Hostgroup::InfoCommand, HttpProxy::InfoCommand, HammerCLIForeman::Image::InfoCommand, HammerCLIForeman::Interface::InfoCommand, Location::InfoCommand, Medium::InfoCommand, Model::InfoCommand, OperatingSystem::InfoCommand, Organization::InfoCommand, PartitionTable::DumpCommand, PartitionTable::InfoCommand, PersonalAccessToken::InfoCommand, PuppetClass::InfoCommand, PuppetEnvironment::InfoCommand, Realm::InfoCommand, ReportTemplate::DumpCommand, ReportTemplate::InfoCommand, Role::InfoCommand, SSHKeys::InfoCommand, SmartClassParameter::InfoCommand, SmartProxy::InfoCommand, SmartVariable::InfoCommand, Subnet::InfoCommand, Template::DumpCommand, Template::InfoCommand, User::InfoCommand, Usergroup::InfoCommand
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Command
alias_name_for_resource, build_options, connection_name, create_option_builder, #customized_options, #dependency_resolver, dependency_resolver, #exception_handler_class, #get_identifier, #get_resource_id, #get_resource_ids, #request_params, resolver, #resolver, resource_alias_name_mapping, resource_config, resource_name_mapping, #searchables, searchables, #transform_format
Class Method Details
.command_name(name = nil) ⇒ Object
477
478
479
|
# File 'lib/hammer_cli_foreman/commands.rb', line 477
def self.command_name(name=nil)
super(name) || "info"
end
|
.output(definition = nil, &block) ⇒ Object
468
469
470
471
472
473
474
475
|
# File 'lib/hammer_cli_foreman/commands.rb', line 468
def self.output(definition = nil, &block)
super
begin
output_definition.update_field_sets('THIN', (searchables.for(resource).map(&:name) + ['id']).map(&:to_sym))
rescue StandardError => e
end
end
|
Instance Method Details
#extend_data(record) ⇒ Object
486
487
488
|
# File 'lib/hammer_cli_foreman/commands.rb', line 486
def extend_data(record)
record
end
|
#print_data(record) ⇒ Object
490
491
492
|
# File 'lib/hammer_cli_foreman/commands.rb', line 490
def print_data(record)
print_record(output_definition, record)
end
|
#send_request ⇒ Object
481
482
483
484
|
# File 'lib/hammer_cli_foreman/commands.rb', line 481
def send_request
record = super
extend_data(record)
end
|