Class: Sequel::SQL::JoinOnClause
- Inherits:
-
JoinClause
- Object
- Expression
- SpecificExpression
- JoinClause
- Sequel::SQL::JoinOnClause
- Defined in:
- lib/sequel_core/sql.rb
Overview
Represents an SQL JOIN table ON conditions clause.
Instance Attribute Summary collapse
-
#on ⇒ Object
readonly
The conditions for the join.
Attributes inherited from JoinClause
#join_type, #table, #table_alias
Instance Method Summary collapse
-
#initialize(on, *args) ⇒ JoinOnClause
constructor
Create an object with the given conditions and default value.
-
#to_s(ds) ⇒ Object
Delegate the creation of the resulting SQL to the given dataset, since it may be database dependent.
Methods inherited from Expression
Constructor Details
#initialize(on, *args) ⇒ JoinOnClause
Create an object with the given conditions and default value.
656 657 658 659 |
# File 'lib/sequel_core/sql.rb', line 656 def initialize(on, *args) @on = on super(*args) end |
Instance Attribute Details
#on ⇒ Object (readonly)
The conditions for the join
652 653 654 |
# File 'lib/sequel_core/sql.rb', line 652 def on @on end |
Instance Method Details
#to_s(ds) ⇒ Object
Delegate the creation of the resulting SQL to the given dataset, since it may be database dependent.
663 664 665 |
# File 'lib/sequel_core/sql.rb', line 663 def to_s(ds) ds.join_on_clause_sql(self) end |