package Library::Schema::CD;
use base qw/DBIx::Class/;
- __PACKAGE__->load_components(qw/PK::Auto Core/); # for example
+ __PACKAGE__->load_components(qw/PK::Auto::Pg Core/); # for example
__PACKAGE__->table('cd');
# Elsewhere in your code:
=head3 Arguments: <target> <@db_info>
-This method takes a target namespace, as well as dbh connection info,
-and creates a L<DBIx::Class::DB> class as well as subclasses for each of
-your database classes in this namespace, using this connection.
+This is the most important method in this class. it takes a target namespace,
+as well as dbh connection info, and creates a L<DBIx::Class::DB> class as
+well as subclasses for each of your database classes in this namespace, using
+this connection.
It will also setup a ->class method on the target class, which lets you
resolve database classes based on the schema component name, for example
return $schema;
}
-=head2 compose_namespace
-
-=head3 Arguments: <target> <base>
-
-Translates <base> namespace into the specified <target> namespace.
-For example
-
- My::Schema->compose_connection('A::B::C', @conn_info);
-
-My::Schema::Tableclasses would become A::B::C::Tableclasses.
-
-=cut
-
sub compose_namespace {
my ($self, $target, $base) = @_;
my %reg = %{ $self->source_registrations };