Module: Neo4j::Shared::ClassMethods

Defined in:
lib/neo4j/shared.rb

Instance Method Summary collapse

Instance Method Details

#current_transactionObject

remove?


21
22
23
# File 'lib/neo4j/shared.rb', line 21

def current_transaction
  Neo4j::ActiveBase.current_transaction
end

#neo4j_query(*args) ⇒ Object

This should be used everywhere. Should make it easy to support a session-per-model system


27
28
29
# File 'lib/neo4j/shared.rb', line 27

def neo4j_query(*args)
  Neo4j::ActiveBase.query(*args)
end

#neo4j_sessionObject

remove?


16
17
18
# File 'lib/neo4j/shared.rb', line 16

def neo4j_session
  Neo4j::ActiveBase.current_session
end

#new_queryObject


31
32
33
# File 'lib/neo4j/shared.rb', line 31

def new_query
  Neo4j::ActiveBase.new_query
end