Class: IronTrail::QueryTransformer
- Inherits:
-
Object
- Object
- IronTrail::QueryTransformer
- Defined in:
- lib/iron_trail/query_transformer.rb
Constant Summary collapse
- METADATA_MAX_LENGTH =
1 MiB
1048576
Instance Attribute Summary collapse
-
#transformer_proc ⇒ Object
readonly
Returns the value of attribute transformer_proc.
Instance Method Summary collapse
-
#initialize ⇒ QueryTransformer
constructor
A new instance of QueryTransformer.
- #setup_active_record ⇒ Object
Constructor Details
#initialize ⇒ QueryTransformer
Returns a new instance of QueryTransformer.
9 10 11 |
# File 'lib/iron_trail/query_transformer.rb', line 9 def initialize @transformer_proc = create_query_transformer_proc end |
Instance Attribute Details
#transformer_proc ⇒ Object (readonly)
Returns the value of attribute transformer_proc.
7 8 9 |
# File 'lib/iron_trail/query_transformer.rb', line 7 def transformer_proc @transformer_proc end |
Instance Method Details
#setup_active_record ⇒ Object
13 14 15 |
# File 'lib/iron_trail/query_transformer.rb', line 13 def setup_active_record ActiveRecord.query_transformers << @transformer_proc end |