Graph/Undirected.pm

filter: Statementstmt 100% 15 / 15 Branchbran 100% 2 / 2 Conditioncond 100% 3 / 3 MC/DCmcdc 100% 2 / 2 Subroutinesub 100% 5 / 5 Podpod 100% 1 / 1 totaltotal 100% 28 / 28 CC 3 SCAR 6.2
CC
3
Cov
100%
new
3.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.9
« Graph/MSTHeapElem.pm ↑ Summary Graph/Matrix.pm »
1 package Graph::Undirected;
2  
3 36 ▶use Graph;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 36 ▶use base 'Graph';
Subroutine BEGIN: called CC=1 SCAR=0.0
5 36 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 36 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 =pod
9  
10 =head1 NAME
11  
12 Graph::Undirected - undirected graphs
13  
14 =head1 SYNOPSIS
15  
16 use Graph::Undirected;
17 my $g = Graph::Undirected->new;
18  
19 # Or alternatively:
20  
21 use Graph;
22 my $g = Graph->new(undirected => 1);
23 my $g = Graph->new(directed => 0);
24  
25 =head1 DESCRIPTION
26  
27 Graph::Undirected allows you to create undirected graphs.
28  
29 For the available methods, see L<Graph>.
30  
31 =head1 SEE ALSO
32  
33 L<Graph>, L<Graph::Directed>
34  
35 =head1 AUTHOR AND COPYRIGHT
36  
37 Jarkko Hietaniemi F<jhi@iki.fi>
38  
39 =head1 LICENSE
40  
41 This module is licensed under the same terms as Perl itself.
42  
43 =cut
44  
45 1448 ▶sub new {
Subroutine new: called CC=3 SCAR=11.0
Pod documented
46 1448 my $class = shift;
47 1448 ▶ $class->SUPER::new((ref $class && $class->directed) ? () : (undirected => 1), @_);
Branch: 1 branch
BranchTrueFalseTotal
ref $class && $class->directed ? : 3 1445 1448
Condition100%3/3
ref $class and $class->directed
!ll&&!rl&&r
15212933
MC/DC100%2/2
ref $class and $class->directed
ref $class $class->directed
Truth table100%3/3
A and B
A= ref $classB= $class->directed
ABresult
0X0
100
111
48 }
49  
50 36 1;
« Graph/MSTHeapElem.pm ↑ Summary Graph/Matrix.pm »