Class: ShellDataReportingApIs::FleetmanagementV1TransactionUpdateodometer404ErrorException

Inherits:
APIException
  • Object
show all
Defined in:
lib/shell_data_reporting_ap_is/exceptions/fleetmanagement_v1_transaction_updateodometer404_error_exception.rb

Overview

Fleetmanagement V1 Transaction Updateodometer 404 Error class.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(reason, response) ⇒ FleetmanagementV1TransactionUpdateodometer404ErrorException

The constructor.

Parameters:

  • The (String)

    reason for raising an exception.

  • The (HttpResponse)

    HttpReponse of the API call.



19
20
21
22
23
# File 'lib/shell_data_reporting_ap_is/exceptions/fleetmanagement_v1_transaction_updateodometer404_error_exception.rb', line 19

def initialize(reason, response)
  super(reason, response)
  hash = APIHelper.json_deserialize(@response.raw_body)
  unbox(hash)
end

Instance Attribute Details

#faultFault

TODO: Write general description for this method

Returns:



14
15
16
# File 'lib/shell_data_reporting_ap_is/exceptions/fleetmanagement_v1_transaction_updateodometer404_error_exception.rb', line 14

def fault
  @fault
end

Instance Method Details

#unbox(hash) ⇒ Object

Populates this object by extracting properties from a hash. response body.

Parameters:

  • The (Hash)

    deserialized response sent by the server in the



28
29
30
# File 'lib/shell_data_reporting_ap_is/exceptions/fleetmanagement_v1_transaction_updateodometer404_error_exception.rb', line 28

def unbox(hash)
  @fault = Fault.from_hash(hash['fault']) if hash['fault']
end