Exception: Msf::RPC::JSON::ClientError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/msf/core/rpc/json/error.rb

Overview

Base class for all Msf::RPC::JSON client exceptions.

Direct Known Subclasses

ErrorResponse, InvalidResponse, JSONParseError

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, response: nil) ⇒ ClientError

Instantiate a ClientError object.

Parameters:

  • message (String) (defaults to: nil)

    A String providing a short description of the error.

  • response (Hash) (defaults to: nil)

    A response hash. The default value is nil.



145
146
147
148
# File 'lib/msf/core/rpc/json/error.rb', line 145

def initialize(message = nil, response: nil)
  super(message)
  @response = response
end

Instance Attribute Details

#responseObject (readonly)

Returns the value of attribute response.



139
140
141
# File 'lib/msf/core/rpc/json/error.rb', line 139

def response
  @response
end