=head1 VERSION
-Version 1.10
+Version 1.18
=cut
-our $VERSION = '1.10';
+our $VERSION = '1.18';
=head1 DESCRIPTION
=cut
-use base qw/Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Carp>;
-=head2 C<< new kind => $kind, id => $id, data => $data >>
+=head2 C<new>
+
+ my $tvr = Test::Valgrind::Report->new(
+ kind => $kind,
+ id => $id,
+ data => $data,
+ );
Your usual constructor.
}, $class;
}
-=head2 C<< new_diag $data >>
+=head2 C<new_diag>
+
+ my $diag_report = Test::Valgrind::Report->new_diag($data);
Constructs a report with kind C<'Diag'>, an auto-incremented identifier and the given C<$data>.
=head2 C<kind>
+ my $kind = $tvr->kind;
+
Read-only accessor for the C<kind> option.
=cut
=head2 C<id>
+ my $id = $tvr->id;
+
Read-only accessor for the C<id> option.
=cut
=head2 C<data>
+ my $data = $tvr->data;
+
Read-only accessor for the C<data> option.
=cut
=head2 C<is_diag>
+ $tvr->is_diag;
+
Tells if a report has the C<'Diag'> kind, i.e. is a diagnostic.
=cut
=head2 C<kinds>
+ my @kinds = $tvr->kinds;
+
Returns the list of valid kinds for this report class.
Defaults to C<'Diag'>.
sub kinds { 'Diag' }
-=head2 C<valid_kind $kind>
+=head2 C<valid_kind>
+
+ $tvr->valid_kind($kind);
Tells whether C<$kind> is a valid kind for this report class.
=head1 COPYRIGHT & LICENSE
-Copyright 2009 Vincent Pit, all rights reserved.
+Copyright 2009,2010,2011,2013,2015,2016 Vincent Pit, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.