Class: ActiverecordCallbackLens::Collector::CallbackDefinition
- Inherits:
-
Data
- Object
- Data
- ActiverecordCallbackLens::Collector::CallbackDefinition
- Defined in:
- lib/activerecord_callback_lens/collector/callback_definition.rb
Overview
Represents a single callback registered on an ActiveRecord model.
event + phase together reconstruct the full callback name (e.g. :before + :save => before_save). raw_conditions holds the unprocessed if/unless arrays from AR internals. condition_tree is nil until the Parser populates it (nil when no conditions).
Instance Attribute Summary collapse
-
#condition_tree ⇒ Object
readonly
Returns the value of attribute condition_tree.
-
#event ⇒ Object
readonly
Returns the value of attribute event.
-
#filter ⇒ Object
readonly
Returns the value of attribute filter.
-
#model ⇒ Object
readonly
Returns the value of attribute model.
-
#phase ⇒ Object
readonly
Returns the value of attribute phase.
-
#raw_conditions ⇒ Object
readonly
Returns the value of attribute raw_conditions.
-
#source_location ⇒ Object
readonly
Returns the value of attribute source_location.
Instance Attribute Details
#condition_tree ⇒ Object (readonly)
Returns the value of attribute condition_tree
11 12 13 |
# File 'lib/activerecord_callback_lens/collector/callback_definition.rb', line 11 def condition_tree @condition_tree end |
#event ⇒ Object (readonly)
Returns the value of attribute event
11 12 13 |
# File 'lib/activerecord_callback_lens/collector/callback_definition.rb', line 11 def event @event end |
#filter ⇒ Object (readonly)
Returns the value of attribute filter
11 12 13 |
# File 'lib/activerecord_callback_lens/collector/callback_definition.rb', line 11 def filter @filter end |
#model ⇒ Object (readonly)
Returns the value of attribute model
11 12 13 |
# File 'lib/activerecord_callback_lens/collector/callback_definition.rb', line 11 def model @model end |
#phase ⇒ Object (readonly)
Returns the value of attribute phase
11 12 13 |
# File 'lib/activerecord_callback_lens/collector/callback_definition.rb', line 11 def phase @phase end |
#raw_conditions ⇒ Object (readonly)
Returns the value of attribute raw_conditions
11 12 13 |
# File 'lib/activerecord_callback_lens/collector/callback_definition.rb', line 11 def raw_conditions @raw_conditions end |
#source_location ⇒ Object (readonly)
Returns the value of attribute source_location
11 12 13 |
# File 'lib/activerecord_callback_lens/collector/callback_definition.rb', line 11 def source_location @source_location end |