ClassDiagram/Attribute.pm untested

filter: Statementstmt 0.0% 0 / 21 Branchbran 0.0% 0 / 4 Conditioncond 0.0% 0 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 0.0% 0 / 5 Podpod 0.0% 0 / 2 totaltotal 0.0% 0 / 37 CC 3 SCAR 18.4
CC
3
Cov
0%
new
12.0
ident_color
2.0
BEGIN
2.0
CRAP 6.3
1 package GraphViz::Diagram::ClassDiagram::Attribute;
2 #_{ use
3 use Carp;
4 use GraphViz::Diagram::ClassDiagram;
5 use GraphViz::Diagram::ClassDiagram::ClassElement;
6 #_}
7 our @ISA = qw(GraphViz::Diagram::ClassDiagram::ClassElement);
8  
9 our $VERSION = $GraphViz::Diagram::ClassDiagram::VERSION;
10 #_{ POD: Methods
11 =head1 Methods
12  
13 =cut
14 #_}
15 sub new { #_{
16  
17 #_{ POD
18 =head2 new
19  
20 =cut
21 #_}
22  
23 my $class_myself = shift;
24 my $class = shift;
25 my $ident = shift;
26 my $opts = shift;
27  
28 croak "Attribute - new: passed \$class_myself (= ref:" . (ref $class_myself) . " >$class_myself< is neither an *::Attribute nor a *::Method" unless
29 $class_myself eq 'GraphViz::Diagram::ClassDiagram::Attribute' or
30 $class_myself eq 'GraphViz::Diagram::ClassDiagram::Method';
31  
32 croak "Attribute - new: passed attribute \$class (=$class) is not a GraphViz::Class" unless ref $class eq 'GraphViz::Diagram::ClassDiagram::Class';
33  
34 my $self = $class_myself->SUPER::new($class, $ident, $opts);
35  
36 # bless $self, $class;
37  
38 # $class_myself->SUPER::new($self, $class, $ident, $opts);
39
40  
41 return $self;
42  
43 } #_}
44 sub ident_color { #_{
45 #_{ POD
46 =head2 ident_color
47  
48 Static method. Returns the color for an I<identifier>.
49  
50 Compare with L<GraphViz::Diagram::ClassDiagram/color_comment>
51  
52 =cut
53 #_}
54 return '#3318cd';
55 } #_}
56  
57 'tq84';