class Neo4j::Core::CypherSession::Transactions::Embedded

Public Class Methods

new(*args) click to toggle source
Calls superclass method Neo4j::Transaction::Base::new
   # File lib/neo4j/core/cypher_session/transactions/embedded.rb
 8 def initialize(*args)
 9   super
10   @java_tx = adaptor.graph_db.begin_tx
11 end

Public Instance Methods

commit() click to toggle source
   # File lib/neo4j/core/cypher_session/transactions/embedded.rb
13 def commit
14   return if !@java_tx
15 
16   @java_tx.success
17   @java_tx.close
18 rescue Java::OrgNeo4jGraphdb::TransactionFailureException => e
19   raise CypherError, e.message
20 end
delete() click to toggle source
   # File lib/neo4j/core/cypher_session/transactions/embedded.rb
22 def delete
23   return if !@java_tx
24 
25   @java_tx.failure
26   @java_tx.close
27 end