Exception: Hpe3parSdk::HTTPTeaPot

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) ⇒ HTTPTeaPot

Returns a new instance of HTTPTeaPot.



349
350
351
352
353
354
355
# File 'lib/Hpe3parSdk/exceptions.rb', line 349

def initialize(code = nil, message =nil, ref =nil, http_status=nil)
  @http_status = 418
  @message = 'I' 'm A Teapot. (RFC 2324)'
  super(code, message.nil? ? @message : message,
        ref,
        http_status.nil? ? @http_status : http_status)
end

Instance Attribute Details

#http_statusObject (readonly)

HTTP 418 - I’m a Tea Pot



346
347
348
# File 'lib/Hpe3parSdk/exceptions.rb', line 346

def http_status
  @http_status
end

#messageObject (readonly)

HTTP 418 - I’m a Tea Pot



346
347
348
# File 'lib/Hpe3parSdk/exceptions.rb', line 346

def message
  @message
end