Class: CrossJoinUnnest
- Inherits:
-
Object
- Object
- CrossJoinUnnest
- Defined in:
- lib/lilit_sql.rb
Instance Attribute Summary collapse
-
#from ⇒ Object
Returns the value of attribute from.
-
#ordinality ⇒ Object
Returns the value of attribute ordinality.
-
#row ⇒ Object
Returns the value of attribute row.
Instance Method Summary collapse
- #alias_name ⇒ Object
-
#initialize(from, row, ordinality) ⇒ CrossJoinUnnest
constructor
A new instance of CrossJoinUnnest.
- #rows ⇒ Object
Constructor Details
#initialize(from, row, ordinality) ⇒ CrossJoinUnnest
Returns a new instance of CrossJoinUnnest.
173 174 175 176 177 |
# File 'lib/lilit_sql.rb', line 173 def initialize(from, row, ordinality) @from = from @row = row @ordinality = ordinality end |
Instance Attribute Details
#from ⇒ Object
Returns the value of attribute from.
171 172 173 |
# File 'lib/lilit_sql.rb', line 171 def from @from end |
#ordinality ⇒ Object
Returns the value of attribute ordinality.
171 172 173 |
# File 'lib/lilit_sql.rb', line 171 def ordinality @ordinality end |
#row ⇒ Object
Returns the value of attribute row.
171 172 173 |
# File 'lib/lilit_sql.rb', line 171 def row @row end |
Instance Method Details
#alias_name ⇒ Object
183 184 185 |
# File 'lib/lilit_sql.rb', line 183 def alias_name @from.source.table_name end |
#rows ⇒ Object
179 180 181 |
# File 'lib/lilit_sql.rb', line 179 def rows [@row].map {|r| r.with_from(@from)} end |