Class: CohortScope::Cohort
- Inherits:
-
Arel::Nodes::Node
- Object
- Arel::Nodes::Node
- CohortScope::Cohort
- Defined in:
- lib/cohort_scope/cohort.rb
Direct Known Subclasses
Constant Summary collapse
- IMPOSSIBLE =
'1 = 2'
Instance Method Summary collapse
- #expr ⇒ Object (also: #to_sql)
-
#initialize(active_record, characteristics, minimum_cohort_size) ⇒ Cohort
constructor
A new instance of Cohort.
Constructor Details
#initialize(active_record, characteristics, minimum_cohort_size) ⇒ Cohort
Returns a new instance of Cohort.
5 6 7 8 9 |
# File 'lib/cohort_scope/cohort.rb', line 5 def initialize(active_record, characteristics, minimum_cohort_size) @active_record = active_record @characteristics = characteristics @minimum_cohort_size = minimum_cohort_size end |
Instance Method Details
#expr ⇒ Object Also known as: to_sql
11 12 13 |
# File 'lib/cohort_scope/cohort.rb', line 11 def expr @expr ||= resolve end |