class Nodeum::TapeDrivesApi

Attributes

api_client[RW]

Public Class Methods

new(api_client = ApiClient.default) click to toggle source
# File lib/nodeum_sdk/api/tape_drives_api.rb, line 19
def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Public Instance Methods

create_tape_drive_by_tape_library(tape_library_id, tape_drive_body, opts = {}) click to toggle source

Creates a new tape drive. **API Key Scope**: tape_drives / create @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_body [TapeDrive] @param [Hash] opts the optional parameters @return [TapeDrive]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 28
def create_tape_drive_by_tape_library(tape_library_id, tape_drive_body, opts = {})
  data, _status_code, _headers = create_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_body, opts)
  data
end
create_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_body, opts = {}) click to toggle source

Creates a new tape drive. **API Key Scope**: tape_drives / create @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_body [TapeDrive] @param [Hash] opts the optional parameters @return [Array<(TapeDrive, Integer, Hash)>] TapeDrive data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 39
def create_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.create_tape_drive_by_tape_library ...'
  end
  # verify the required parameter 'tape_library_id' is set
  if @api_client.config.client_side_validation && tape_library_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_library_id' when calling TapeDrivesApi.create_tape_drive_by_tape_library"
  end
  # verify the required parameter 'tape_drive_body' is set
  if @api_client.config.client_side_validation && tape_drive_body.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_body' when calling TapeDrivesApi.create_tape_drive_by_tape_library"
  end
  # resource path
  local_var_path = '/tape_libraries/{tape_library_id}/tape_drives'.sub('{' + 'tape_library_id' + '}', CGI.escape(tape_library_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] || @api_client.object_to_http_body(tape_drive_body) 

  # return_type
  return_type = opts[:return_type] || 'TapeDrive' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#create_tape_drive_by_tape_library\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
destroy_tape_drive(tape_drive_id, opts = {}) click to toggle source

Destroys a specific tape drive. **API Key Scope**: tape_drives / destroy @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [nil]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 97
def destroy_tape_drive(tape_drive_id, opts = {})
  destroy_tape_drive_with_http_info(tape_drive_id, opts)
  nil
end
destroy_tape_drive_by_tape_library(tape_library_id, tape_drive_id, opts = {}) click to toggle source

Destroys a specific tape drive. **API Key Scope**: tape_drives / destroy @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [nil]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 158
def destroy_tape_drive_by_tape_library(tape_library_id, tape_drive_id, opts = {})
  destroy_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, opts)
  nil
end
destroy_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, opts = {}) click to toggle source

Destroys a specific tape drive. **API Key Scope**: tape_drives / destroy @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 169
def destroy_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.destroy_tape_drive_by_tape_library ...'
  end
  # verify the required parameter 'tape_library_id' is set
  if @api_client.config.client_side_validation && tape_library_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_library_id' when calling TapeDrivesApi.destroy_tape_drive_by_tape_library"
  end
  # verify the required parameter 'tape_drive_id' is set
  if @api_client.config.client_side_validation && tape_drive_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_id' when calling TapeDrivesApi.destroy_tape_drive_by_tape_library"
  end
  # resource path
  local_var_path = '/tape_libraries/{tape_library_id}/tape_drives/{tape_drive_id}'.sub('{' + 'tape_library_id' + '}', CGI.escape(tape_library_id.to_s)).sub('{' + 'tape_drive_id' + '}', CGI.escape(tape_drive_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#destroy_tape_drive_by_tape_library\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
destroy_tape_drive_with_http_info(tape_drive_id, opts = {}) click to toggle source

Destroys a specific tape drive. **API Key Scope**: tape_drives / destroy @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 107
def destroy_tape_drive_with_http_info(tape_drive_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.destroy_tape_drive ...'
  end
  # verify the required parameter 'tape_drive_id' is set
  if @api_client.config.client_side_validation && tape_drive_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_id' when calling TapeDrivesApi.destroy_tape_drive"
  end
  # resource path
  local_var_path = '/tape_drives/{tape_drive_id}'.sub('{' + 'tape_drive_id' + '}', CGI.escape(tape_drive_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#destroy_tape_drive\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
index_tape_drive_devices(tape_library_id, job_id, opts = {}) click to toggle source

Lists tape drives devices. **API Key Scope**: tape_drives / devices @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param job_id [String] ID of active job @param [Hash] opts the optional parameters @return [TapeDriveDeviceCollection]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 224
def index_tape_drive_devices(tape_library_id, job_id, opts = {})
  data, _status_code, _headers = index_tape_drive_devices_with_http_info(tape_library_id, job_id, opts)
  data
end
index_tape_drive_devices_with_http_info(tape_library_id, job_id, opts = {}) click to toggle source

Lists tape drives devices. **API Key Scope**: tape_drives / devices @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param job_id [String] ID of active job @param [Hash] opts the optional parameters @return [Array<(TapeDriveDeviceCollection, Integer, Hash)>] TapeDriveDeviceCollection data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 235
def index_tape_drive_devices_with_http_info(tape_library_id, job_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.index_tape_drive_devices ...'
  end
  # verify the required parameter 'tape_library_id' is set
  if @api_client.config.client_side_validation && tape_library_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_library_id' when calling TapeDrivesApi.index_tape_drive_devices"
  end
  # verify the required parameter 'job_id' is set
  if @api_client.config.client_side_validation && job_id.nil?
    fail ArgumentError, "Missing the required parameter 'job_id' when calling TapeDrivesApi.index_tape_drive_devices"
  end
  # resource path
  local_var_path = '/tape_libraries/{tape_library_id}/tape_drives/-/devices'.sub('{' + 'tape_library_id' + '}', CGI.escape(tape_library_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'job_id'] = job_id

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json', 'queued', 'working', 'failed', ])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] || 'TapeDriveDeviceCollection' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#index_tape_drive_devices\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
index_tape_drives(opts = {}) click to toggle source

Lists all tape drives. **API Key Scope**: tape_drives / index @param [Hash] opts the optional parameters @option opts [Integer] :limit The number of items to display for pagination. @option opts [Integer] :offset The number of items to skip for pagination. @option opts [Array<String>] :sort_by Sort results by attribute. Can sort on multiple attributes, separated by &#x60;|&#x60;. Order direction can be suffixing the attribute by either &#x60;:asc&#x60; (default) or &#x60;:desc&#x60;. @option opts [String] :id Filter on id @option opts [String] :tape_library_id Filter on tape library id @option opts [String] :name Filter on name @option opts [String] :serial Filter on serial @option opts [String] :comment Filter on comment @option opts [String] :scsi_address Filter on scsi address @option opts [String] :vendor Filter on vendor @option opts [String] :product Filter on product @option opts [String] :firmware Filter on firmware @option opts [String] :device Filter on device @option opts [String] :sgdevice Filter on sgdevice @option opts [String] :libso Filter on libso @option opts [String] :acs Filter on acs @option opts [String] :lsm Filter on lsm @option opts [String] :panel Filter on panel @option opts [String] :transport Filter on transport @option opts [String] :status Filter on status @option opts [String] :full Filter on full @option opts [String] :mount_count Filter on mount count @option opts [String] :use_to Filter on use to @option opts [String] :use_by Filter on use by @option opts [String] :barcode Filter on barcode @option opts [String] :task_id Filter on task id @option opts [String] :use_file_processed_size Filter on use file processed size @option opts [String] :use_file_size_to_process Filter on use file size to process @option opts [String] :use_file_name_processed Filter on use file name processed @option opts [String] :bandwidth Filter on bandwidth @return [TapeDriveCollection]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 321
def index_tape_drives(opts = {})
  data, _status_code, _headers = index_tape_drives_with_http_info(opts)
  data
end
index_tape_drives_by_tape_library(tape_library_id, opts = {}) click to toggle source

Lists all tape drives. **API Key Scope**: tape_drives / index @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param [Hash] opts the optional parameters @option opts [Integer] :limit The number of items to display for pagination. @option opts [Integer] :offset The number of items to skip for pagination. @option opts [Array<String>] :sort_by Sort results by attribute. Can sort on multiple attributes, separated by &#x60;|&#x60;. Order direction can be suffixing the attribute by either &#x60;:asc&#x60; (default) or &#x60;:desc&#x60;. @option opts [String] :id Filter on id @option opts [String] :name Filter on name @option opts [String] :serial Filter on serial @option opts [String] :comment Filter on comment @option opts [String] :scsi_address Filter on scsi address @option opts [String] :vendor Filter on vendor @option opts [String] :product Filter on product @option opts [String] :firmware Filter on firmware @option opts [String] :device Filter on device @option opts [String] :sgdevice Filter on sgdevice @option opts [String] :libso Filter on libso @option opts [String] :acs Filter on acs @option opts [String] :lsm Filter on lsm @option opts [String] :panel Filter on panel @option opts [String] :transport Filter on transport @option opts [String] :status Filter on status @option opts [String] :full Filter on full @option opts [String] :mount_count Filter on mount count @option opts [String] :use_to Filter on use to @option opts [String] :use_by Filter on use by @option opts [String] :barcode Filter on barcode @option opts [String] :task_id Filter on task id @option opts [String] :use_file_processed_size Filter on use file processed size @option opts [String] :use_file_size_to_process Filter on use file size to process @option opts [String] :use_file_name_processed Filter on use file name processed @option opts [String] :bandwidth Filter on bandwidth @return [TapeDriveCollection]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 467
def index_tape_drives_by_tape_library(tape_library_id, opts = {})
  data, _status_code, _headers = index_tape_drives_by_tape_library_with_http_info(tape_library_id, opts)
  data
end
index_tape_drives_by_tape_library_with_http_info(tape_library_id, opts = {}) click to toggle source

Lists all tape drives. **API Key Scope**: tape_drives / index @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param [Hash] opts the optional parameters @option opts [Integer] :limit The number of items to display for pagination. @option opts [Integer] :offset The number of items to skip for pagination. @option opts [Array<String>] :sort_by Sort results by attribute. Can sort on multiple attributes, separated by &#x60;|&#x60;. Order direction can be suffixing the attribute by either &#x60;:asc&#x60; (default) or &#x60;:desc&#x60;. @option opts [String] :id Filter on id @option opts [String] :name Filter on name @option opts [String] :serial Filter on serial @option opts [String] :comment Filter on comment @option opts [String] :scsi_address Filter on scsi address @option opts [String] :vendor Filter on vendor @option opts [String] :product Filter on product @option opts [String] :firmware Filter on firmware @option opts [String] :device Filter on device @option opts [String] :sgdevice Filter on sgdevice @option opts [String] :libso Filter on libso @option opts [String] :acs Filter on acs @option opts [String] :lsm Filter on lsm @option opts [String] :panel Filter on panel @option opts [String] :transport Filter on transport @option opts [String] :status Filter on status @option opts [String] :full Filter on full @option opts [String] :mount_count Filter on mount count @option opts [String] :use_to Filter on use to @option opts [String] :use_by Filter on use by @option opts [String] :barcode Filter on barcode @option opts [String] :task_id Filter on task id @option opts [String] :use_file_processed_size Filter on use file processed size @option opts [String] :use_file_size_to_process Filter on use file size to process @option opts [String] :use_file_name_processed Filter on use file name processed @option opts [String] :bandwidth Filter on bandwidth @return [Array<(TapeDriveCollection, Integer, Hash)>] TapeDriveCollection data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 506
def index_tape_drives_by_tape_library_with_http_info(tape_library_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.index_tape_drives_by_tape_library ...'
  end
  # verify the required parameter 'tape_library_id' is set
  if @api_client.config.client_side_validation && tape_library_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_library_id' when calling TapeDrivesApi.index_tape_drives_by_tape_library"
  end
  # resource path
  local_var_path = '/tape_libraries/{tape_library_id}/tape_drives'.sub('{' + 'tape_library_id' + '}', CGI.escape(tape_library_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
  query_params[:'sort_by'] = @api_client.build_collection_param(opts[:'sort_by'], :pipe) if !opts[:'sort_by'].nil?
  query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil?
  query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
  query_params[:'serial'] = opts[:'serial'] if !opts[:'serial'].nil?
  query_params[:'comment'] = opts[:'comment'] if !opts[:'comment'].nil?
  query_params[:'scsi_address'] = opts[:'scsi_address'] if !opts[:'scsi_address'].nil?
  query_params[:'vendor'] = opts[:'vendor'] if !opts[:'vendor'].nil?
  query_params[:'product'] = opts[:'product'] if !opts[:'product'].nil?
  query_params[:'firmware'] = opts[:'firmware'] if !opts[:'firmware'].nil?
  query_params[:'device'] = opts[:'device'] if !opts[:'device'].nil?
  query_params[:'sgdevice'] = opts[:'sgdevice'] if !opts[:'sgdevice'].nil?
  query_params[:'libso'] = opts[:'libso'] if !opts[:'libso'].nil?
  query_params[:'acs'] = opts[:'acs'] if !opts[:'acs'].nil?
  query_params[:'lsm'] = opts[:'lsm'] if !opts[:'lsm'].nil?
  query_params[:'panel'] = opts[:'panel'] if !opts[:'panel'].nil?
  query_params[:'transport'] = opts[:'transport'] if !opts[:'transport'].nil?
  query_params[:'status'] = opts[:'status'] if !opts[:'status'].nil?
  query_params[:'full'] = opts[:'full'] if !opts[:'full'].nil?
  query_params[:'mount_count'] = opts[:'mount_count'] if !opts[:'mount_count'].nil?
  query_params[:'use_to'] = opts[:'use_to'] if !opts[:'use_to'].nil?
  query_params[:'use_by'] = opts[:'use_by'] if !opts[:'use_by'].nil?
  query_params[:'barcode'] = opts[:'barcode'] if !opts[:'barcode'].nil?
  query_params[:'task_id'] = opts[:'task_id'] if !opts[:'task_id'].nil?
  query_params[:'use_file_processed_size'] = opts[:'use_file_processed_size'] if !opts[:'use_file_processed_size'].nil?
  query_params[:'use_file_size_to_process'] = opts[:'use_file_size_to_process'] if !opts[:'use_file_size_to_process'].nil?
  query_params[:'use_file_name_processed'] = opts[:'use_file_name_processed'] if !opts[:'use_file_name_processed'].nil?
  query_params[:'bandwidth'] = opts[:'bandwidth'] if !opts[:'bandwidth'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] || 'TapeDriveCollection' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#index_tape_drives_by_tape_library\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
index_tape_drives_with_http_info(opts = {}) click to toggle source

Lists all tape drives. **API Key Scope**: tape_drives / index @param [Hash] opts the optional parameters @option opts [Integer] :limit The number of items to display for pagination. @option opts [Integer] :offset The number of items to skip for pagination. @option opts [Array<String>] :sort_by Sort results by attribute. Can sort on multiple attributes, separated by &#x60;|&#x60;. Order direction can be suffixing the attribute by either &#x60;:asc&#x60; (default) or &#x60;:desc&#x60;. @option opts [String] :id Filter on id @option opts [String] :tape_library_id Filter on tape library id @option opts [String] :name Filter on name @option opts [String] :serial Filter on serial @option opts [String] :comment Filter on comment @option opts [String] :scsi_address Filter on scsi address @option opts [String] :vendor Filter on vendor @option opts [String] :product Filter on product @option opts [String] :firmware Filter on firmware @option opts [String] :device Filter on device @option opts [String] :sgdevice Filter on sgdevice @option opts [String] :libso Filter on libso @option opts [String] :acs Filter on acs @option opts [String] :lsm Filter on lsm @option opts [String] :panel Filter on panel @option opts [String] :transport Filter on transport @option opts [String] :status Filter on status @option opts [String] :full Filter on full @option opts [String] :mount_count Filter on mount count @option opts [String] :use_to Filter on use to @option opts [String] :use_by Filter on use by @option opts [String] :barcode Filter on barcode @option opts [String] :task_id Filter on task id @option opts [String] :use_file_processed_size Filter on use file processed size @option opts [String] :use_file_size_to_process Filter on use file size to process @option opts [String] :use_file_name_processed Filter on use file name processed @option opts [String] :bandwidth Filter on bandwidth @return [Array<(TapeDriveCollection, Integer, Hash)>] TapeDriveCollection data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 360
def index_tape_drives_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.index_tape_drives ...'
  end
  # resource path
  local_var_path = '/tape_drives'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
  query_params[:'sort_by'] = @api_client.build_collection_param(opts[:'sort_by'], :pipe) if !opts[:'sort_by'].nil?
  query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil?
  query_params[:'tape_library_id'] = opts[:'tape_library_id'] if !opts[:'tape_library_id'].nil?
  query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
  query_params[:'serial'] = opts[:'serial'] if !opts[:'serial'].nil?
  query_params[:'comment'] = opts[:'comment'] if !opts[:'comment'].nil?
  query_params[:'scsi_address'] = opts[:'scsi_address'] if !opts[:'scsi_address'].nil?
  query_params[:'vendor'] = opts[:'vendor'] if !opts[:'vendor'].nil?
  query_params[:'product'] = opts[:'product'] if !opts[:'product'].nil?
  query_params[:'firmware'] = opts[:'firmware'] if !opts[:'firmware'].nil?
  query_params[:'device'] = opts[:'device'] if !opts[:'device'].nil?
  query_params[:'sgdevice'] = opts[:'sgdevice'] if !opts[:'sgdevice'].nil?
  query_params[:'libso'] = opts[:'libso'] if !opts[:'libso'].nil?
  query_params[:'acs'] = opts[:'acs'] if !opts[:'acs'].nil?
  query_params[:'lsm'] = opts[:'lsm'] if !opts[:'lsm'].nil?
  query_params[:'panel'] = opts[:'panel'] if !opts[:'panel'].nil?
  query_params[:'transport'] = opts[:'transport'] if !opts[:'transport'].nil?
  query_params[:'status'] = opts[:'status'] if !opts[:'status'].nil?
  query_params[:'full'] = opts[:'full'] if !opts[:'full'].nil?
  query_params[:'mount_count'] = opts[:'mount_count'] if !opts[:'mount_count'].nil?
  query_params[:'use_to'] = opts[:'use_to'] if !opts[:'use_to'].nil?
  query_params[:'use_by'] = opts[:'use_by'] if !opts[:'use_by'].nil?
  query_params[:'barcode'] = opts[:'barcode'] if !opts[:'barcode'].nil?
  query_params[:'task_id'] = opts[:'task_id'] if !opts[:'task_id'].nil?
  query_params[:'use_file_processed_size'] = opts[:'use_file_processed_size'] if !opts[:'use_file_processed_size'].nil?
  query_params[:'use_file_size_to_process'] = opts[:'use_file_size_to_process'] if !opts[:'use_file_size_to_process'].nil?
  query_params[:'use_file_name_processed'] = opts[:'use_file_name_processed'] if !opts[:'use_file_name_processed'].nil?
  query_params[:'bandwidth'] = opts[:'bandwidth'] if !opts[:'bandwidth'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] || 'TapeDriveCollection' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#index_tape_drives\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
show_tape_drive(tape_drive_id, opts = {}) click to toggle source

Displays a specific tape drive. **API Key Scope**: tape_drives / show @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [TapeDrive]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 587
def show_tape_drive(tape_drive_id, opts = {})
  data, _status_code, _headers = show_tape_drive_with_http_info(tape_drive_id, opts)
  data
end
show_tape_drive_by_tape_library(tape_library_id, tape_drive_id, opts = {}) click to toggle source

Displays a specific tape drive. **API Key Scope**: tape_drives / show @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [TapeDrive]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 650
def show_tape_drive_by_tape_library(tape_library_id, tape_drive_id, opts = {})
  data, _status_code, _headers = show_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, opts)
  data
end
show_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, opts = {}) click to toggle source

Displays a specific tape drive. **API Key Scope**: tape_drives / show @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [Array<(TapeDrive, Integer, Hash)>] TapeDrive data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 661
def show_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.show_tape_drive_by_tape_library ...'
  end
  # verify the required parameter 'tape_library_id' is set
  if @api_client.config.client_side_validation && tape_library_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_library_id' when calling TapeDrivesApi.show_tape_drive_by_tape_library"
  end
  # verify the required parameter 'tape_drive_id' is set
  if @api_client.config.client_side_validation && tape_drive_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_id' when calling TapeDrivesApi.show_tape_drive_by_tape_library"
  end
  # resource path
  local_var_path = '/tape_libraries/{tape_library_id}/tape_drives/{tape_drive_id}'.sub('{' + 'tape_library_id' + '}', CGI.escape(tape_library_id.to_s)).sub('{' + 'tape_drive_id' + '}', CGI.escape(tape_drive_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] || 'TapeDrive' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#show_tape_drive_by_tape_library\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
show_tape_drive_with_http_info(tape_drive_id, opts = {}) click to toggle source

Displays a specific tape drive. **API Key Scope**: tape_drives / show @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param [Hash] opts the optional parameters @return [Array<(TapeDrive, Integer, Hash)>] TapeDrive data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 597
def show_tape_drive_with_http_info(tape_drive_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.show_tape_drive ...'
  end
  # verify the required parameter 'tape_drive_id' is set
  if @api_client.config.client_side_validation && tape_drive_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_id' when calling TapeDrivesApi.show_tape_drive"
  end
  # resource path
  local_var_path = '/tape_drives/{tape_drive_id}'.sub('{' + 'tape_drive_id' + '}', CGI.escape(tape_drive_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] 

  # return_type
  return_type = opts[:return_type] || 'TapeDrive' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#show_tape_drive\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tape_drive(tape_drive_id, tape_drive_body, opts = {}) click to toggle source

Updates a specific tape drive. **API Key Scope**: tape_drives / update @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param tape_drive_body [TapeDrive] @param [Hash] opts the optional parameters @return [TapeDrive]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 718
def update_tape_drive(tape_drive_id, tape_drive_body, opts = {})
  data, _status_code, _headers = update_tape_drive_with_http_info(tape_drive_id, tape_drive_body, opts)
  data
end
update_tape_drive_by_tape_library(tape_library_id, tape_drive_id, tape_drive_body, opts = {}) click to toggle source

Updates a specific tape drive. **API Key Scope**: tape_drives / update @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param tape_drive_body [TapeDrive] @param [Hash] opts the optional parameters @return [TapeDrive]

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 789
def update_tape_drive_by_tape_library(tape_library_id, tape_drive_id, tape_drive_body, opts = {})
  data, _status_code, _headers = update_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, tape_drive_body, opts)
  data
end
update_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, tape_drive_body, opts = {}) click to toggle source

Updates a specific tape drive. **API Key Scope**: tape_drives / update @param tape_library_id [String] Numeric ID, serial, or name of tape library. @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param tape_drive_body [TapeDrive] @param [Hash] opts the optional parameters @return [Array<(TapeDrive, Integer, Hash)>] TapeDrive data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 801
def update_tape_drive_by_tape_library_with_http_info(tape_library_id, tape_drive_id, tape_drive_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.update_tape_drive_by_tape_library ...'
  end
  # verify the required parameter 'tape_library_id' is set
  if @api_client.config.client_side_validation && tape_library_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_library_id' when calling TapeDrivesApi.update_tape_drive_by_tape_library"
  end
  # verify the required parameter 'tape_drive_id' is set
  if @api_client.config.client_side_validation && tape_drive_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_id' when calling TapeDrivesApi.update_tape_drive_by_tape_library"
  end
  # verify the required parameter 'tape_drive_body' is set
  if @api_client.config.client_side_validation && tape_drive_body.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_body' when calling TapeDrivesApi.update_tape_drive_by_tape_library"
  end
  # resource path
  local_var_path = '/tape_libraries/{tape_library_id}/tape_drives/{tape_drive_id}'.sub('{' + 'tape_library_id' + '}', CGI.escape(tape_library_id.to_s)).sub('{' + 'tape_drive_id' + '}', CGI.escape(tape_drive_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] || @api_client.object_to_http_body(tape_drive_body) 

  # return_type
  return_type = opts[:return_type] || 'TapeDrive' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#update_tape_drive_by_tape_library\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end
update_tape_drive_with_http_info(tape_drive_id, tape_drive_body, opts = {}) click to toggle source

Updates a specific tape drive. **API Key Scope**: tape_drives / update @param tape_drive_id [String] Numeric ID, serial, or name of tape drive. @param tape_drive_body [TapeDrive] @param [Hash] opts the optional parameters @return [Array<(TapeDrive, Integer, Hash)>] TapeDrive data, response status code and response headers

# File lib/nodeum_sdk/api/tape_drives_api.rb, line 729
def update_tape_drive_with_http_info(tape_drive_id, tape_drive_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: TapeDrivesApi.update_tape_drive ...'
  end
  # verify the required parameter 'tape_drive_id' is set
  if @api_client.config.client_side_validation && tape_drive_id.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_id' when calling TapeDrivesApi.update_tape_drive"
  end
  # verify the required parameter 'tape_drive_body' is set
  if @api_client.config.client_side_validation && tape_drive_body.nil?
    fail ArgumentError, "Missing the required parameter 'tape_drive_body' when calling TapeDrivesApi.update_tape_drive"
  end
  # resource path
  local_var_path = '/tape_drives/{tape_drive_id}'.sub('{' + 'tape_drive_id' + '}', CGI.escape(tape_drive_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:body] || @api_client.object_to_http_body(tape_drive_body) 

  # return_type
  return_type = opts[:return_type] || 'TapeDrive' 

  # auth_names
  auth_names = opts[:auth_names] || ['BasicAuth', 'BearerAuth']

  new_options = opts.merge(
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: TapeDrivesApi#update_tape_drive\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end