Exception: OrientDbClient::ProtocolError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/orient_db_client/exceptions.rb

Direct Known Subclasses

RecordNotFound

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(session, *exceptions) ⇒ ProtocolError

Returns a new instance of ProtocolError.



12
13
14
15
16
17
# File 'lib/orient_db_client/exceptions.rb', line 12

def initialize(session, *exceptions)
	@session
	@exception_class = exceptions[0] && exceptions[0][:exception_class]

	super exceptions.map { |exp| [ exp[:exception_class], exp[:exception_message] ].reject { |s| s.nil? }.join(': ') }.join("\n")
end

Instance Attribute Details

#exception_classObject (readonly)

Returns the value of attribute exception_class.



10
11
12
# File 'lib/orient_db_client/exceptions.rb', line 10

def exception_class
  @exception_class
end

#sessionObject (readonly)

Returns the value of attribute session.



9
10
11
# File 'lib/orient_db_client/exceptions.rb', line 9

def session
  @session
end