Exception: Neography::NeographyError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/neography/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, code = nil, stacktrace = nil, request = nil, index = 0) ⇒ NeographyError


6
7
8
9
10
11
12
# File 'lib/neography/errors.rb', line 6

def initialize(message = nil, code = nil, stacktrace = nil, request = nil, index = 0)
  @message    = message
  @code       = code
  @stacktrace = stacktrace
  @request    = request
  @index      = index
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code


4
5
6
# File 'lib/neography/errors.rb', line 4

def code
  @code
end

#indexObject (readonly)

Returns the value of attribute index


4
5
6
# File 'lib/neography/errors.rb', line 4

def index
  @index
end

#messageObject (readonly)

Returns the value of attribute message


4
5
6
# File 'lib/neography/errors.rb', line 4

def message
  @message
end

#requestObject (readonly)

Returns the value of attribute request


4
5
6
# File 'lib/neography/errors.rb', line 4

def request
  @request
end

#stacktraceObject (readonly)

Returns the value of attribute stacktrace


4
5
6
# File 'lib/neography/errors.rb', line 4

def stacktrace
  @stacktrace
end

Instance Method Details

#to_sObject


14
15
16
# File 'lib/neography/errors.rb', line 14

def to_s
 "NeographyError: \n--message: #{@message}, \n--code: #{@code}, \n--stacktrace: #{@stacktrace}, \n--request: #{@request}, \n--index: #{@index}"
end