Class: Arel::From
- Defined in:
- lib/arel/algebra/relations/operations/from.rb
Instance Attribute Summary collapse
-
#sources ⇒ Object
readonly
Returns the value of attribute sources.
Attributes inherited from Compound
Attributes included from Relation
Instance Method Summary collapse
- #eval ⇒ Object
-
#initialize(relation, sources) ⇒ From
constructor
A new instance of From.
Methods inherited from Compound
#attributes, #column_for, #externalizable?, #join?, #joins, #name, #skipped, #table, #table_alias, #table_sql, #taken, #unoperated_rows
Methods included from Relation
#[], #alias, #attributes, #bind, #call, #christener, #compiler, #delete, #each, #exclusion_predicate_sql, #externalizable?, #externalize, #find_attribute_matching_name, #from, #from_clauses, #group_clauses, #groupings, #having_clauses, #havings, #inclusion_predicate_sql, #insert, #inserts, #join, #join?, #joins, #lock, #locked, #order_clauses, #orders, #outer_join, #position_of, #primary_key, #project, #projections, #select_clauses, #session, #skip, #skipped, #take, #taken, #to_sql, #update, #where, #where_clauses, #wheres
Constructor Details
#initialize(relation, sources) ⇒ From
Returns a new instance of From.
5 6 7 8 |
# File 'lib/arel/algebra/relations/operations/from.rb', line 5 def initialize relation, sources super(relation) @sources = sources end |
Instance Attribute Details
#sources ⇒ Object (readonly)
Returns the value of attribute sources.
3 4 5 |
# File 'lib/arel/algebra/relations/operations/from.rb', line 3 def sources @sources end |
Instance Method Details
#eval ⇒ Object
10 11 12 |
# File 'lib/arel/algebra/relations/operations/from.rb', line 10 def eval unoperated_rows[sources..-1] end |