]> git.donarmstrong.com Git - debbugs.git/commitdiff
document Debbugs::DB::ResultSet
authorDon Armstrong <don@donarmstrong.com>
Sun, 26 Feb 2017 15:42:22 +0000 (07:42 -0800)
committerDon Armstrong <don@donarmstrong.com>
Sun, 26 Feb 2017 15:42:22 +0000 (07:42 -0800)
Debbugs/DB/ResultSet/Maintainer.pm

index 280a6e5ab498da0fb1a503be4d2a8a50d18a07da..7c889f314c728cd47f38555f4ba867e8dbde8b1a 100644 (file)
@@ -27,7 +27,20 @@ use base 'DBIx::Class::ResultSet';
 use Debbugs::DB::Util qw(select_one);
 
 
+=over
 
+=item get_maintainers 
+
+     $s->resultset('Maintainers')->get_maintainers();
+
+     $s->resultset('Maintainers')->get_maintainers(@maints);
+
+Retrieve a HASHREF of all maintainers with the maintainer name as the key and
+the id of the database as the value. If given an optional list of maintainers,
+adds those maintainers to the database if they do not already exist in the
+database.
+
+=cut
 sub get_maintainers {
     my ($self,@maints) = @_;
     my %maints;
@@ -53,6 +66,16 @@ sub get_maintainers {
     return \%maints;
 }
 
+=item get_maintainer_id
+
+     $s->resultset('Maintainer')->get_maintainer_id('Foo Bar <baz@example.com>')
+
+Given a maintainer name returns the maintainer id, possibly inserting the
+maintainer (and correspondent) if either do not exist in the database.
+
+
+=cut
+
 sub get_maintainer_id {
     my ($self,$maint) = @_;
     my $rs =
@@ -85,6 +108,10 @@ SQL
              );
 }
 
+=back
+
+=cut
+
 1;
 
 __END__