Module: HammerCLIKatello::ApipieHelper
- Included in:
- ContentExportHelper, ContentViewPurgeCommand
- Defined in:
- lib/hammer_cli_katello/apipie_helper.rb
Instance Method Summary collapse
- #call(action, resource, options = {}) ⇒ Object
- #destroy(resource, options = {}) ⇒ Object
- #index(resource, options = {}) ⇒ Object
- #show(resource, options = {}) ⇒ Object
- #update(resource, options = {}) ⇒ Object
Instance Method Details
#call(action, resource, options = {}) ⇒ Object
19 20 21 |
# File 'lib/hammer_cli_katello/apipie_helper.rb', line 19 def call(action, resource, = {}) HammerCLIForeman.foreman_resource(resource).call(action, ) end |
#destroy(resource, options = {}) ⇒ Object
15 16 17 |
# File 'lib/hammer_cli_katello/apipie_helper.rb', line 15 def destroy(resource, = {}) call(:destroy, resource, ) end |
#index(resource, options = {}) ⇒ Object
7 8 9 |
# File 'lib/hammer_cli_katello/apipie_helper.rb', line 7 def index(resource, = {}) call(:index, resource, )['results'] end |
#show(resource, options = {}) ⇒ Object
3 4 5 |
# File 'lib/hammer_cli_katello/apipie_helper.rb', line 3 def show(resource, = {}) call(:show, resource, ) end |
#update(resource, options = {}) ⇒ Object
11 12 13 |
# File 'lib/hammer_cli_katello/apipie_helper.rb', line 11 def update(resource, = {}) call(:update, resource, )['results'] end |