blib/lib/XML/Stream/XPath.pm

filter: Statementstmt 78.5% 22 / 28 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 87.5% 7 / 8 Podpod 0.0% 0 / 1 totaltotal 74.3% 29 / 39 CC 2 SCAR 7.5
CC
2
Cov
73%
AddFunction
6.0
BEGIN
1.0
BEGIN
1.0
CRAP 2.1
« blib/lib/XML/Stream/XPath/Value.pm ↑ Summary blib/lib/XML/Stream/IO/Select/Win32.pm »
1 ##############################################################################
2 #
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Library General Public
5 # License as published by the Free Software Foundation; either
6 # version 2 of the License, or (at your option) any later version.
7 #
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # Library General Public License for more details.
12 #
13 # You should have received a copy of the GNU Library General Public
14 # License along with this library; if not, write to the
15 # Free Software Foundation, Inc., 59 Temple Place - Suite 330,
16 # Boston, MA 02111-1307, USA.
17 #
18 # Jabber
19 # Copyright (C) 1998-2004 Jabber Software Foundation http://jabber.org/
20 #
21 ##############################################################################
22  
23 package XML::Stream::XPath;
24  
25 12 ▶use 5.008;
Subroutine BEGIN: called CC=1 SCAR=0.0
26 12 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
27 12 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
28 12 ▶use vars qw( $VERSION %FUNCTIONS );
Subroutine BEGIN: called CC=1 SCAR=0.0
29  
30 12 $VERSION = "1.23_06";
31  
32 12 ▶use XML::Stream::XPath::Value;
Subroutine BEGIN: called CC=1 SCAR=0.0
33 12 ▶use XML::Stream::XPath::Op;
Subroutine BEGIN: called CC=1 SCAR=0.0
34 12 ▶use XML::Stream::XPath::Query;
Subroutine BEGIN: called CC=1 SCAR=0.0
35  
36 sub AddFunction
37 {
38 0 ▶ my $function = shift;
Subroutine AddFunction: not called CC=2 SCAR=17.9
Pod undocumented
39 0 my $code = shift;
40 0 ▶ if (!defined($code))
Branch: 1 branch
BranchTrueFalseTotal
unless (defined $code) 0 0 0
41 {
42 0 delete($FUNCTIONS{$code});
43 0 return;
44 }
45  
46 0 $FUNCTIONS{$function} = $code;
47 }
48  
49  
50 12 1;
51  
« blib/lib/XML/Stream/XPath/Value.pm ↑ Summary blib/lib/XML/Stream/IO/Select/Win32.pm »