Class: ActiveRecord::ConnectionAdapters::CassandraAdapter

Inherits:
JdbcAdapter
  • Object
show all
Includes:
ArJdbc::Cassandra
Defined in:
lib/arjdbc/cassandra/adapter.rb

Constant Summary collapse

@@quoted_table_names =

some QUOTING caching :

{}
@@quoted_column_names =
{}

Constants included from ArJdbc::Cassandra

ArJdbc::Cassandra::ADAPTER_NAME, ArJdbc::Cassandra::NATIVE_DATABASE_TYPES, ArJdbc::Cassandra::VERSION

Instance Method Summary collapse

Methods included from ArJdbc::Cassandra

#adapter_name, arel2_visitors, #case_sensitive_modifier, column_selector, #create_database, #create_table, #drop_database, #drop_table, #exec_insert, extended, jdbc_connection_class, #limited_update_conditions, #native_database_types, #recreate_database, #select, #structure_dump, #supports_bulk_alter?, #supports_index_sort_order?, #supports_migrations?, #supports_primary_key?, #supports_savepoints?, #supports_transaction_isolation?, #supports_views?

Instance Method Details

#jdbc_column_classObject



13
14
15
# File 'lib/arjdbc/cassandra/adapter.rb', line 13

def jdbc_column_class
  CassandraColumn
end

#jdbc_connection_class(spec) ⇒ Object



9
10
11
# File 'lib/arjdbc/cassandra/adapter.rb', line 9

def jdbc_connection_class(spec)
  ::ArJdbc::Cassandra.jdbc_connection_class
end

#quote_column_name(name) ⇒ Object



32
33
34
35
36
37
38
# File 'lib/arjdbc/cassandra/adapter.rb', line 32

def quote_column_name(name)
  unless quoted = @@quoted_column_names[name]
    quoted = super
    @@quoted_column_names[name] = quoted.freeze
  end
  quoted
end

#quote_table_name(name) ⇒ Object



22
23
24
25
26
27
28
# File 'lib/arjdbc/cassandra/adapter.rb', line 22

def quote_table_name(name)
  unless quoted = @@quoted_table_names[name]
    quoted = super
    @@quoted_table_names[name] = quoted.freeze
  end
  quoted
end