Class: MsRestAzure::CloudErrorData

Inherits:
Object
  • Object
show all
Defined in:
lib/ms_rest_azure/cloud_error_data.rb

Overview

Class which represents keeps aux data about Azure invalid response.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#codeString

Returns the error code parsed from the body of the http error response.

Returns:

  • (String)

    the error code parsed from the body of the http error response.



12
13
14
# File 'lib/ms_rest_azure/cloud_error_data.rb', line 12

def code
  @code
end

#messageString

Returns the error message parsed from the body of the http error response.

Returns:

  • (String)

    the error message parsed from the body of the http error response.



15
16
17
# File 'lib/ms_rest_azure/cloud_error_data.rb', line 15

def message
  @message
end

Class Method Details

.deserialize_object(object) ⇒ CloudErrorData

Deserializes given hash into CloudErrorData object.

Parameters:

  • object (Hash)

    object to deserialize.

Returns:



22
23
24
25
26
27
28
29
30
31
# File 'lib/ms_rest_azure/cloud_error_data.rb', line 22

def self.deserialize_object(object)
  return if object.nil?
  output_object = CloudErrorData.new

  output_object.code = object['code']

  output_object.message = object['message']

  output_object
end