Class: Arel::Visitors::ToSql
- Inherits:
-
Object
- Object
- Arel::Visitors::ToSql
- Defined in:
- lib/xbar/rails3/arel.rb
Instance Method Summary collapse
- #quote(value, column = nil) ⇒ Object
- #quote_column_name(name) ⇒ Object
- #quote_table_name(name) ⇒ Object
Instance Method Details
#quote(value, column = nil) ⇒ Object
2 3 4 |
# File 'lib/xbar/rails3/arel.rb', line 2 def quote value, column = nil ActiveRecord::Base.connection.quote value, column end |
#quote_column_name(name) ⇒ Object
10 11 12 |
# File 'lib/xbar/rails3/arel.rb', line 10 def quote_column_name name Arel::Nodes::SqlLiteral === name ? name : ActiveRecord::Base.connection.quote_column_name(name) end |
#quote_table_name(name) ⇒ Object
6 7 8 |
# File 'lib/xbar/rails3/arel.rb', line 6 def quote_table_name name ActiveRecord::Base.connection.quote_table_name(name) end |