Exception: Hpe3parSdk::HTTPUnauthorized

Inherits:
HPE3PARException show all
Defined in:
lib/Hpe3parSdk/exceptions.rb

Instance Attribute Summary collapse

Attributes inherited from HPE3PARException

#code, #ref

Instance Method Summary collapse

Constructor Details

#initialize(code = nil, message = nil, ref = nil, http_status = nil) ⇒ HTTPUnauthorized

HTTP 401 - Unauthorized: bad credentials.



100
101
102
103
104
105
106
# File 'lib/Hpe3parSdk/exceptions.rb', line 100

def initialize(code = nil, message =nil, ref =nil, http_status=nil)
  @http_status = 401
  @message ='Unauthorized'
  super(code, message.nil? ? @message : message,
        ref,
        http_status.nil? ? @http_status : http_status)
end

Instance Attribute Details

#http_statusObject (readonly)

Returns the value of attribute http_status.



97
98
99
# File 'lib/Hpe3parSdk/exceptions.rb', line 97

def http_status
  @http_status
end

#messageObject (readonly)

Returns the value of attribute message.



97
98
99
# File 'lib/Hpe3parSdk/exceptions.rb', line 97

def message
  @message
end