Phylo/Unparsers/Abstract.pm

filter: Statementstmt 96.3% 26 / 27 Branchbran 75.0% 3 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 83.3% 5 / 6 Podpod n/a totaltotal 91.8% 34 / 37 CC 4 SCAR 8.9
CC
4
Cov
94%
_new
4.0
_logger
2.0
BEGIN
1.0
CRAP 2.4
« Phylo/NeXML/DOM/Document.pm ↑ Summary Phylo/NeXML/DOM/Element.pm »
1 package Bio::Phylo::Unparsers::Abstract;
2 9 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 9 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 9 ▶use base 'Bio::Phylo::IO';
Subroutine BEGIN: called CC=1 SCAR=0.0
5 9 ▶use Bio::Phylo::Util::Logger;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 9 my $logger = Bio::Phylo::Util::Logger->new;
7  
8 =head1 NAME
9  
10 Bio::Phylo::Unparsers::Abstract - Superclass for unparsers used by Bio::Phylo::IO
11  
12 =head1 DESCRIPTION
13  
14 This package is subclassed by all other packages within Bio::Phylo::Unparsers::.*.
15 There is no direct usage.
16  
17 =cut
18  
19 0 ▶sub _logger { $logger }
Subroutine _logger: not called CC=1 SCAR=6.9
20  
21 37 ▶sub _new {
Subroutine _new: called CC=4 SCAR=13.9
22 37 my $class = shift;
23 37 my $self = {};
24 37 ▶ if (@_) {
Branch: 1 branch
BranchTrueFalseTotal
if (@_) 37 0 37
25 37 my %opts = @_;
26 37 for my $key ( keys %opts ) {
27 97 my $localkey = uc $key;
28 97 $localkey =~ s/-//;
29 97 ▶ unless ( ref $opts{$key} ) {
Branch: 1 branch
BranchTrueFalseTotal
if (ref $opts{$key}) { } 42 55 97
30 55 $self->{$localkey} = uc $opts{$key};
31 }
32 else {
33 42 $self->{$localkey} = $opts{$key};
34 }
35 }
36 }
37 37 bless $self, $class;
38 37 return $self;
39 }
40  
41 # podinherit_insert_token
42  
43 =head1 SEE ALSO
44  
45 There is a mailing list at L<https://groups.google.com/forum/#!forum/bio-phylo>
46 for any user or developer questions and discussions.
47  
48 =over
49  
50 =item L<Bio::Phylo::IO>
51  
52 The parsers are called by the L<Bio::Phylo::IO> object.
53 Look there for examples.
54  
55 =item L<Bio::Phylo::Manual>
56  
57 Also see the manual: L<Bio::Phylo::Manual> and L<http://rutgervos.blogspot.com>.
58  
59 =back
60  
61 =head1 CITATION
62  
63 If you use Bio::Phylo in published research, please cite it:
64  
65 B<Rutger A Vos>, B<Jason Caravas>, B<Klaas Hartmann>, B<Mark A Jensen>
66 and B<Chase Miller>, 2011. Bio::Phylo - phyloinformatic analysis using Perl.
67 I<BMC Bioinformatics> B<12>:63.
68 L<http://dx.doi.org/10.1186/1471-2105-12-63>
69  
70 =cut
71  
72 9 1;
« Phylo/NeXML/DOM/Document.pm ↑ Summary Phylo/NeXML/DOM/Element.pm »