Class: Pacer::Neo4j2::TransactionEventHandler

Inherits:
Object
  • Object
show all
Defined in:
lib/pacer-neo4j2/transaction_event_handler.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(graph) ⇒ TransactionEventHandler

Returns a new instance of TransactionEventHandler.



9
10
11
# File 'lib/pacer-neo4j2/transaction_event_handler.rb', line 9

def initialize(graph)
  @graph = graph
end

Instance Attribute Details

#before_commitObject

Returns the value of attribute before_commit.



7
8
9
# File 'lib/pacer-neo4j2/transaction_event_handler.rb', line 7

def before_commit
  @before_commit
end

#graphObject (readonly)

Returns the value of attribute graph.



6
7
8
# File 'lib/pacer-neo4j2/transaction_event_handler.rb', line 6

def graph
  @graph
end

#on_commitObject

Returns the value of attribute on_commit.



7
8
9
# File 'lib/pacer-neo4j2/transaction_event_handler.rb', line 7

def on_commit
  @on_commit
end

#on_commit_failedObject

Returns the value of attribute on_commit_failed.



7
8
9
# File 'lib/pacer-neo4j2/transaction_event_handler.rb', line 7

def on_commit_failed
  @on_commit_failed
end

Instance Method Details

#unregister!Object



13
14
15
# File 'lib/pacer-neo4j2/transaction_event_handler.rb', line 13

def unregister!
  graph.drop_handler self
end