line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package W3C::SOAP::WSDL::Utils; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
# Created on: 2013-06-27 17:13:29 |
4
|
|
|
|
|
|
|
# Create by: Ivan Wills |
5
|
|
|
|
|
|
|
# $Id$ |
6
|
|
|
|
|
|
|
# $Revision$, $HeadURL$, $Date$ |
7
|
|
|
|
|
|
|
# $Revision$, $Source$, $Date$ |
8
|
|
|
|
|
|
|
|
9
|
5
|
|
|
5
|
|
22
|
use strict; |
|
5
|
|
|
|
|
5
|
|
|
5
|
|
|
|
|
1010
|
|
10
|
5
|
|
|
5
|
|
25
|
use warnings; |
|
5
|
|
|
|
|
6
|
|
|
5
|
|
|
|
|
99
|
|
11
|
5
|
|
|
5
|
|
20
|
use version; |
|
5
|
|
|
|
|
27
|
|
|
5
|
|
|
|
|
22
|
|
12
|
5
|
|
|
5
|
|
219
|
use Carp; |
|
5
|
|
|
|
|
7
|
|
|
5
|
|
|
|
|
214
|
|
13
|
5
|
|
|
5
|
|
22
|
use Scalar::Util; |
|
5
|
|
|
|
|
3
|
|
|
5
|
|
|
|
|
133
|
|
14
|
5
|
|
|
5
|
|
18
|
use List::Util; |
|
5
|
|
|
|
|
7
|
|
|
5
|
|
|
|
|
172
|
|
15
|
5
|
|
|
5
|
|
18
|
use Data::Dumper qw/Dumper/; |
|
5
|
|
|
|
|
6
|
|
|
5
|
|
|
|
|
196
|
|
16
|
5
|
|
|
5
|
|
18
|
use English qw/ -no_match_vars /; |
|
5
|
|
|
|
|
5
|
|
|
5
|
|
|
|
|
20
|
|
17
|
5
|
|
|
5
|
|
3160
|
use W3C::SOAP::WSDL::Meta::Method; |
|
5
|
|
|
|
|
14
|
|
|
5
|
|
|
|
|
1182
|
|
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
Moose::Exporter->setup_import_methods( |
20
|
|
|
|
|
|
|
with_meta => ['operation'], |
21
|
|
|
|
|
|
|
); |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
our $VERSION = version->new('0.11'); |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
sub operation { |
26
|
0
|
|
|
0
|
1
|
|
my ( $meta, $name, %options ) = @_; |
27
|
|
|
|
|
|
|
$meta->add_method( |
28
|
|
|
|
|
|
|
$name, |
29
|
|
|
|
|
|
|
W3C::SOAP::WSDL::Meta::Method->wrap( |
30
|
0
|
|
|
0
|
|
|
body => sub { shift->_request($name => @_) }, |
31
|
0
|
|
|
|
|
|
package_name => $meta->name, |
32
|
|
|
|
|
|
|
name => $name, |
33
|
|
|
|
|
|
|
%options, |
34
|
|
|
|
|
|
|
) |
35
|
|
|
|
|
|
|
); |
36
|
0
|
|
|
|
|
|
return; |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
1; |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
__END__ |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
=head1 NAME |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
W3C::SOAP::WSDL::Utils - WSDL related utilities |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
=head1 VERSION |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
This documentation refers to W3C::SOAP::WSDL::Utils version 0.11 |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=head1 SYNOPSIS |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
use W3C::SOAP::WSDL::Utils; |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
# In a WSDL package to generate an operation method: |
57
|
|
|
|
|
|
|
operation wsdl_op => ( |
58
|
|
|
|
|
|
|
wsdl_operation => 'WsdlOp', |
59
|
|
|
|
|
|
|
in_class +> 'MyApp::Some::XSD', |
60
|
|
|
|
|
|
|
in_attribute +> 'wsdl_op_request', |
61
|
|
|
|
|
|
|
out_class +> 'MyApp::Some::XSD', |
62
|
|
|
|
|
|
|
out_attribute +> 'wsdl_op_response', |
63
|
|
|
|
|
|
|
); |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head1 DESCRIPTION |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
=head1 SUBROUTINES/METHODS |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=head1 MOOSE HELPERS |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=over 4 |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=item C<operation ($name, %optisns)> |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
Generates a SOAP operation method with the name C<$name> |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
The options are: |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
=over 4 |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=item C<wsdl_operation> |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
The name of the operation from the WSDL |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
=item C<in_class> |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
The name of the XSD generated module that the inputs should be made against |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=item C<in_attribute> |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
The particular element form the C<in_class> XSD |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=item C<out_class> |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
The name of the XSD generated module that the outputs should be passed to |
96
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
=item C<out_attribute> |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
The particular element form the C<out_class> XSD that contains the results. |
100
|
|
|
|
|
|
|
|
101
|
|
|
|
|
|
|
=back |
102
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
=back |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
=head1 DIAGNOSTICS |
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
=head1 CONFIGURATION AND ENVIRONMENT |
108
|
|
|
|
|
|
|
|
109
|
|
|
|
|
|
|
=head1 DEPENDENCIES |
110
|
|
|
|
|
|
|
|
111
|
|
|
|
|
|
|
=head1 INCOMPATIBILITIES |
112
|
|
|
|
|
|
|
|
113
|
|
|
|
|
|
|
There are no known bugs in this module. |
114
|
|
|
|
|
|
|
|
115
|
|
|
|
|
|
|
Please report problems to Ivan Wills (ivan.wills@gmail.com). |
116
|
|
|
|
|
|
|
|
117
|
|
|
|
|
|
|
Patches are welcome. |
118
|
|
|
|
|
|
|
|
119
|
|
|
|
|
|
|
=head1 AUTHOR |
120
|
|
|
|
|
|
|
|
121
|
|
|
|
|
|
|
Ivan Wills - (ivan.wills@gmail.com) |
122
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
=head1 LICENSE AND COPYRIGHT |
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
Copyright (c) 2013 Ivan Wills (14 Mullion Close, Hornsby Heights, NSW Australia 2077). |
126
|
|
|
|
|
|
|
All rights reserved. |
127
|
|
|
|
|
|
|
|
128
|
|
|
|
|
|
|
This module is free software; you can redistribute it and/or modify it under |
129
|
|
|
|
|
|
|
the same terms as Perl itself. See L<perlartistic>. This program is |
130
|
|
|
|
|
|
|
distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; |
131
|
|
|
|
|
|
|
without even the implied warranty of MERCHANTABILITY or FITNESS FOR A |
132
|
|
|
|
|
|
|
PARTICULAR PURPOSE. |
133
|
|
|
|
|
|
|
|
134
|
|
|
|
|
|
|
=cut |