aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters
diff options
context:
space:
mode:
authoryui-knk <spiketeika@gmail.com>2015-09-08 20:23:20 +0900
committeryui-knk <spiketeika@gmail.com>2015-09-08 21:02:25 +0900
commit1fbd954e6a16df557be184cba6949ee0424d7680 (patch)
tree0eefd108ca025be224077450b7dcf027562167e7 /activerecord/lib/active_record/connection_adapters
parente75b92c032ddbd0e664c4fd241bec5668e35ee96 (diff)
downloadrails-1fbd954e6a16df557be184cba6949ee0424d7680.tar.gz
rails-1fbd954e6a16df557be184cba6949ee0424d7680.tar.bz2
rails-1fbd954e6a16df557be184cba6949ee0424d7680.zip
Define `SchemaStatements#tables` as interface
These 3 methods expect `ConnectionAdapters` to have `tables` method, so make it clear that `tables` method is interface. * `ConnectionAdapters::SchemaCache#prepare_tables` * `db:schema:cache:dump` task * `SchemaDumper#tables`
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters')
-rw-r--r--activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
index 4653904105..16266b4c16 100644
--- a/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
+++ b/activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb
@@ -23,6 +23,12 @@ module ActiveRecord
table_name[0...table_alias_length].tr('.', '_')
end
+ # Returns an array of table names.
+ #
+ def tables(name = nil)
+ raise NotImplementedError, "tables is not implemented"
+ end
+
# Checks to see if the table +table_name+ exists on the database.
#
# table_exists?(:developers)