Module: Arel::Visitors
- Defined in:
- lib/arel/visitors.rb,
lib/arel/visitors/dot.rb,
lib/arel/visitors/mssql.rb,
lib/arel/visitors/mysql.rb,
lib/arel/visitors/ibm_db.rb,
lib/arel/visitors/oracle.rb,
lib/arel/visitors/sqlite.rb,
lib/arel/visitors/to_sql.rb,
lib/arel/visitors/visitor.rb,
lib/arel/visitors/informix.rb,
lib/arel/visitors/join_sql.rb,
lib/arel/visitors/where_sql.rb,
lib/arel/visitors/postgresql.rb,
lib/arel/visitors/depth_first.rb,
lib/arel/visitors/bind_visitor.rb,
lib/arel/visitors/order_clauses.rb
Defined Under Namespace
Modules: BindVisitor, JoinSql Classes: DepthFirst, Dot, IBM_DB, Informix, MSSQL, MySQL, Oracle, OrderClauses, PostgreSQL, SQLite, ToSql, Visitor, WhereSql
Constant Summary collapse
- VISITORS =
{ 'postgresql' => Arel::Visitors::PostgreSQL, 'mysql' => Arel::Visitors::MySQL, 'mysql2' => Arel::Visitors::MySQL, 'mssql' => Arel::Visitors::MSSQL, 'sqlserver' => Arel::Visitors::MSSQL, 'oracle_enhanced' => Arel::Visitors::Oracle, 'sqlite' => Arel::Visitors::SQLite, 'sqlite3' => Arel::Visitors::SQLite, 'ibm_db' => Arel::Visitors::IBM_DB, 'informix' => Arel::Visitors::Informix, }
- ENGINE_VISITORS =
Hash.new do |hash, engine| pool = engine.connection_pool adapter = pool.spec.config[:adapter] hash[engine] = (VISITORS[adapter] || Visitors::ToSql).new(engine) end
Class Method Summary collapse
- .visitor_for(engine) ⇒ Object (also: for)
Class Method Details
.visitor_for(engine) ⇒ Object Also known as: for
37 38 39 |
# File 'lib/arel/visitors.rb', line 37 def self.visitor_for engine ENGINE_VISITORS[engine] end |