Promote resolve_relationship_condition to a 1st-class API method
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / ResultSource / Table.pm
index 7c8dbe7..450be9a 100644 (file)
@@ -3,10 +3,7 @@ package DBIx::Class::ResultSource::Table;
 use strict;
 use warnings;
 
-use DBIx::Class::ResultSet;
-
-use base qw/DBIx::Class/;
-__PACKAGE__->load_components(qw/ResultSource/);
+use base 'DBIx::Class::ResultSource';
 
 =head1 NAME
 
@@ -26,17 +23,22 @@ Returns the FROM entry for the table (i.e. the table name)
 
 =cut
 
-sub from { shift->name; }
-
-1;
+sub from {
+  $_[0]->throw_exception('from() is not a setter method') if @_ > 1;
+  $_[0]->name;
+}
 
-=head1 AUTHOR AND CONTRIBUTORS
+=head1 FURTHER QUESTIONS?
 
-See L<AUTHOR|DBIx::Class/AUTHOR> and L<CONTRIBUTORS|DBIx::Class/CONTRIBUTORS> in DBIx::Class
+Check the list of L<additional DBIC resources|DBIx::Class/GETTING HELP/SUPPORT>.
 
-=head1 LICENSE
+=head1 COPYRIGHT AND LICENSE
 
-You may distribute this code under the same terms as Perl itself.
+This module is free software L<copyright|DBIx::Class/COPYRIGHT AND LICENSE>
+by the L<DBIx::Class (DBIC) authors|DBIx::Class/AUTHORS>. You can
+redistribute it and/or modify it under the same terms as the
+L<DBIx::Class library|DBIx::Class/COPYRIGHT AND LICENSE>.
 
 =cut
 
+1;