release
[dbsrgits/DBIx-Class-Schema-Loader.git] / lib / DBIx / Class / Schema / Loader / DBI / Oracle.pm
index 21e535e..6a66410 100644 (file)
@@ -2,11 +2,14 @@ package DBIx::Class::Schema::Loader::DBI::Oracle;
 
 use strict;
 use warnings;
-use base 'DBIx::Class::Schema::Loader::DBI';
+use base qw/
+    DBIx::Class::Schema::Loader::DBI::Component::QuotedDefault
+    DBIx::Class::Schema::Loader::DBI
+/;
 use Carp::Clan qw/^DBIx::Class/;
 use Class::C3;
 
-our $VERSION = '0.04999_12';
+our $VERSION = '0.06001';
 
 =head1 NAME
 
@@ -46,19 +49,14 @@ sub _setup {
     }
 }
 
-
-sub _table_columns {
+sub _table_as_sql {
     my ($self, $table) = @_;
 
-    my $dbh = $self->schema->storage->dbh;
-
-    my $sth = $dbh->prepare($self->schema->storage->sql_maker->select($table, undef, \'1 = 0'));
-    $sth->execute;
-    return \@{$sth->{NAME_lc}};
+    return $self->_quote_table_name($table);
 }
 
 sub _tables_list { 
-    my $self = shift;
+    my ($self, $opts) = @_;
 
     my $dbh = $self->schema->storage->dbh;
 
@@ -75,7 +73,8 @@ sub _tables_list {
         push @tables, $1
           if $table =~ /\A(\w+)\z/;
     }
-    return @tables;
+
+    return $self->_filter_tables(\@tables, $opts);
 }
 
 sub _table_uniq_info {
@@ -129,11 +128,9 @@ sub _columns_info_for {
 }
 
 sub _extra_column_info {
-    my ($self, $info) = @_;
+    my ($self, $table, $column, $info, $dbi_info) = @_;
     my %extra_info;
 
-    my ($table, $column) = @$info{qw/TABLE_NAME COLUMN_NAME/};
-
     my $dbh = $self->schema->storage->dbh;
     my $sth = $dbh->prepare_cached(
         q{
@@ -160,7 +157,7 @@ L<DBIx::Class::Schema::Loader::DBI>
 
 =head1 AUTHOR
 
-See L<DBIx::Class::Schema::Loader/CONTRIBUTORS>.
+See L<DBIx::Class::Schema::Loader/AUTHOR> and L<DBIx::Class::Schema::Loader/CONTRIBUTORS>.
 
 =head1 LICENSE