Module: Rubernate::Callbacks::Runtime
- Defined in:
- lib/rubernate/callbacks.rb
Overview
This module contains callback method and included in class Rubernate::Runtime.
Instance Method Summary collapse
-
#after_commit ⇒ Object
It’s invoked if transaction has just been commited.
-
#after_flush ⇒ Object
It’s invoked if after flushing modified objects.
-
#before_commit ⇒ Object
It’s invoked if session/transaction is about to be commited.
-
#before_flush(modified) ⇒ Object
It’s invoked when Rubernate needs to flush modified objects.
-
#on_begin ⇒ Object
It’s invoked on session creation.
-
#on_rollback ⇒ Object
It’s invoked if session/transaction is about to be rolled back.
Instance Method Details
#after_commit ⇒ Object
It’s invoked if transaction has just been commited.
53 54 |
# File 'lib/rubernate/callbacks.rb', line 53 def after_commit end |
#after_flush ⇒ Object
It’s invoked if after flushing modified objects.
62 63 |
# File 'lib/rubernate/callbacks.rb', line 62 def after_flush end |
#before_commit ⇒ Object
It’s invoked if session/transaction is about to be commited.
49 50 |
# File 'lib/rubernate/callbacks.rb', line 49 def before_commit end |
#before_flush(modified) ⇒ Object
It’s invoked when Rubernate needs to flush modified objects. It happens when find_by_query is called or if session is going to be commited.
58 59 |
# File 'lib/rubernate/callbacks.rb', line 58 def before_flush modified end |
#on_begin ⇒ Object
It’s invoked on session creation.
41 42 |
# File 'lib/rubernate/callbacks.rb', line 41 def on_begin end |
#on_rollback ⇒ Object
It’s invoked if session/transaction is about to be rolled back.
45 46 |
# File 'lib/rubernate/callbacks.rb', line 45 def on_rollback end |