line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package SOAP::WSDL::Part; |
2
|
1
|
|
|
1
|
|
453
|
use strict; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
25
|
|
3
|
1
|
|
|
1
|
|
3
|
use warnings; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
26
|
|
4
|
1
|
|
|
1
|
|
2
|
use Carp qw(croak); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
40
|
|
5
|
1
|
|
|
1
|
|
396
|
use Class::Std::Fast::Storable; |
|
1
|
|
|
|
|
13734
|
|
|
1
|
|
|
|
|
5
|
|
6
|
|
|
|
|
|
|
|
7
|
1
|
|
|
1
|
|
94
|
use base qw(SOAP::WSDL::Base); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
398
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
our $VERSION = 3.003; |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
my %element_of :ATTR(:name :default<()>); |
12
|
|
|
|
|
|
|
my %type_of :ATTR(:name :default<()>); |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
sub serialize |
15
|
|
|
|
|
|
|
{ |
16
|
4
|
|
|
4
|
0
|
867
|
my $self = shift; |
17
|
4
|
|
|
|
|
4
|
my $name = shift; |
18
|
4
|
|
|
|
|
15
|
my $data = shift; |
19
|
4
|
|
|
|
|
4
|
my $opt = shift; |
20
|
4
|
|
100
|
|
|
17
|
my $typelib = $opt->{ typelib } || die "No typelib"; |
21
|
3
|
|
|
|
|
2
|
my %ns_map = %{ $opt->{ namespace } }; |
|
3
|
|
|
|
|
8
|
|
22
|
|
|
|
|
|
|
|
23
|
3
|
|
|
|
|
2
|
my $item_name; |
24
|
3
|
100
|
|
|
|
5
|
if ($item_name = $self->get_type() ) { |
|
|
100
|
|
|
|
|
|
25
|
|
|
|
|
|
|
# resolve type |
26
|
1
|
|
|
|
|
5
|
my ($prefix, $localname) = split /:/ , $item_name, 2; |
27
|
1
|
50
|
|
|
|
5
|
my $type = $typelib->find_type( $ns_map{ $prefix }, $localname) |
28
|
|
|
|
|
|
|
or die "type $item_name , $ns_map{ $prefix } not found"; |
29
|
|
|
|
|
|
|
|
30
|
0
|
|
|
|
|
0
|
my $name = $self->get_name(); |
31
|
0
|
|
|
|
|
0
|
return $type->serialize( $name, $data->{ $name }, $opt ); |
32
|
|
|
|
|
|
|
} |
33
|
|
|
|
|
|
|
elsif ( $item_name = $self->get_element() ) { |
34
|
1
|
|
|
|
|
7
|
my ($prefix, $localname) = split /:/ , $item_name, 2; |
35
|
1
|
50
|
|
|
|
3
|
my $element = $typelib->find_element( |
36
|
|
|
|
|
|
|
$ns_map{ $prefix }, |
37
|
|
|
|
|
|
|
$localname |
38
|
|
|
|
|
|
|
) |
39
|
|
|
|
|
|
|
or die "element $item_name , $ns_map{ $prefix } not found"; |
40
|
0
|
|
|
|
|
0
|
$opt->{ qualify } = 1; |
41
|
0
|
|
|
|
|
0
|
return $element->serialize( undef, $data->{ $element->get_name() }, $opt ); |
42
|
|
|
|
|
|
|
} |
43
|
1
|
|
|
|
|
14
|
die "Neither type nor element - don't know what to do"; |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
1; |