line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package SOAP::WSDL::XSD::Typelib::Builtin::anyType; |
2
|
83
|
|
|
83
|
|
905
|
use strict; |
|
83
|
|
|
|
|
96
|
|
|
83
|
|
|
|
|
2223
|
|
3
|
83
|
|
|
83
|
|
275
|
use warnings; |
|
83
|
|
|
|
|
94
|
|
|
83
|
|
|
|
|
1795
|
|
4
|
83
|
|
|
83
|
|
746
|
use Class::Std::Fast::Storable constructor => 'none'; |
|
83
|
|
|
|
|
16279
|
|
|
83
|
|
|
|
|
376
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
our $VERSION = 3.003; |
7
|
|
|
|
|
|
|
|
8
|
11
|
|
|
11
|
0
|
1325
|
sub get_xmlns { 'http://www.w3.org/2001/XMLSchema' }; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
# start_tag creates a XML start tag either for a XML element or a attribute. |
11
|
|
|
|
|
|
|
# The method is highly optimized for performance: |
12
|
|
|
|
|
|
|
# - operates on @_ |
13
|
|
|
|
|
|
|
# - uses no private variables |
14
|
|
|
|
|
|
|
# - uses no blocks |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub start_tag { |
17
|
|
|
|
|
|
|
# return empty string if no second argument ($opt) or no name |
18
|
124
|
100
|
|
124
|
0
|
193
|
return q{} if (! $#_); |
19
|
123
|
100
|
|
|
|
352
|
return q{} if (! exists $_[1]->{ name }); |
20
|
|
|
|
|
|
|
# return attribute start if it's an attribute |
21
|
46
|
100
|
|
|
|
93
|
return qq{ $_[1]->{name}="} if $_[1]->{ attr }; |
22
|
|
|
|
|
|
|
# return with xsi:nil="true" if it is nil |
23
|
|
|
|
|
|
|
return join |
24
|
|
|
|
|
|
|
q{} , |
25
|
|
|
|
|
|
|
"<$_[1]->{ name }" , |
26
|
|
|
|
|
|
|
(defined $_[1]->{ xmlns }) ? qq{ xmlns="$_[1]->{ xmlns }"} : (), |
27
|
|
|
|
|
|
|
$_[0]->serialize_attr($_[1]) , |
28
|
|
|
|
|
|
|
q{ xsi:nil="true"/>} |
29
|
42
|
50
|
|
|
|
82
|
if ($_[1]->{ nil }); |
|
|
100
|
|
|
|
|
|
30
|
|
|
|
|
|
|
# return "empty" start tag if it's empty |
31
|
|
|
|
|
|
|
return join |
32
|
|
|
|
|
|
|
q{}, |
33
|
|
|
|
|
|
|
"<$_[1]->{ name }", |
34
|
|
|
|
|
|
|
(defined $_[1]->{ xmlns }) ? qq{ xmlns="$_[1]->{ xmlns }"} : (), |
35
|
|
|
|
|
|
|
$_[0]->serialize_attr($_[1]) , |
36
|
|
|
|
|
|
|
'/>' |
37
|
41
|
50
|
|
|
|
85
|
if ($_[1]->{ empty }); |
|
|
100
|
|
|
|
|
|
38
|
|
|
|
|
|
|
# return XML element start tag |
39
|
|
|
|
|
|
|
return join |
40
|
|
|
|
|
|
|
q{}, |
41
|
|
|
|
|
|
|
"<$_[1]->{ name }", |
42
|
39
|
50
|
|
|
|
157
|
(defined $_[1]->{ xmlns }) ? qq{ xmlns="$_[1]->{ xmlns }"} : (), |
43
|
|
|
|
|
|
|
, $_[0]->serialize_attr($_[1]) |
44
|
|
|
|
|
|
|
, '>'; |
45
|
|
|
|
|
|
|
} |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
# start_tag creates a XML end tag either for a XML element or a attribute. |
48
|
|
|
|
|
|
|
# The method is highly optimized for performance: |
49
|
|
|
|
|
|
|
# - operates on @_ |
50
|
|
|
|
|
|
|
# - uses no private variables |
51
|
|
|
|
|
|
|
# - uses no blocks |
52
|
|
|
|
|
|
|
sub end_tag { |
53
|
|
|
|
|
|
|
# return empty string if no second argument ($opt) or no name |
54
|
112
|
100
|
|
112
|
0
|
274
|
return q{} if (! $#_); |
55
|
100
|
100
|
|
|
|
283
|
return q{} if (! exists $_[1]->{ name }); |
56
|
42
|
100
|
|
|
|
89
|
return q{"} if $_[1]->{ attr }; |
57
|
38
|
|
|
|
|
191
|
return "$_[1]->{name}>"; |
58
|
|
|
|
|
|
|
}; |
59
|
|
|
|
|
|
|
|
60
|
54
|
|
|
54
|
0
|
133
|
sub serialize_attr {}; |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
# sub serialize { q{} }; |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
sub serialize_qualified :STRINGIFY { |
65
|
15
|
|
|
15
|
0
|
3135
|
return $_[0]->serialize( { qualified => 1 } ); |
66
|
83
|
|
|
83
|
|
30386
|
} |
|
83
|
|
|
|
|
126
|
|
|
83
|
|
|
|
|
468
|
|
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
sub as_list :ARRAYIFY { |
69
|
2
|
|
|
2
|
0
|
324
|
return [ $_[0] ]; |
70
|
83
|
|
|
83
|
|
14469
|
} |
|
83
|
|
|
|
|
106
|
|
|
83
|
|
|
|
|
292
|
|
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
Class::Std::initialize(); # make :STRINGIFY overloading work |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
1; |
75
|
|
|
|
|
|
|
|