=head1 NAME XML::Compile::WSDL11::Operation - defines a possible SOAP interaction =head1 INHERITANCE =head1 SYNOPSIS # created by XML::Compile::WSDL11 =head1 DESCRIPTION These objects are created by L, grouping information about a certain specific message interchange between a client and a server. You can better (try to) create a WSDL file itself, then attempt to instantiate these objects yourself... or even better: use L directly, and forget WSDL complexity. There are three styles of SOAP: Document-style, RPC-literal and RPC-encoded. The first can be used directly, for the SOAP-RPC will require you to specify more information about the expected message types. =head1 METHODS =head2 Constructors $obj-EB(OPTIONS) =over 4 The OPTIONS are all collected from the WSDL description by L. End-users should not attempt to initiate this object directly. Option --Default action bind_op undef binding name port portType port_op protocol 'HTTP' service style | 'document' wsdl . action => URI . bind_op => HASH . binding => HASH . name => STRING . port => HASH . portType => HASH . port_op => HASH . protocol => URI|'HTTP' =over 4 C is short for C, which is a constant to indicate that transport should use the HyperText Transfer Protocol. =back . service => HASH . style => 'document'|'rpc' . wsdl => XML::Compile::WSDL11 object =back =head2 Accessors $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back =head2 Use $obj-EB =over 4 Returns the list of alternative URLs for the end-point, which should be defined within the service's port declaration. =back $obj-EB =over 4 This returns the type of operation this is. There are four kinds, which are returned as strings C, C, C, and C. The latter two are initiated by a server, the former two by a client. =back $obj-EB =over 4 =back $obj-EB =over 4 =back $obj-EB =over 4 =back =head2 Handlers $obj-EB(OPTIONS) =over 4 Returns one CODE reference which handles the processing for this operation. You pass that CODE reference an input message of the correct type, as pure Perl HASH structure. An 'request-response' operation will return then answer, or C in case of failure. An 'one-way' operation with return C in case of failure, and a true value when successfull. Besides the OPTIONS listed, you can also specify anything which is accepted by L, like C<< sloppy_integers => 1 >> or hooks. Option --Default endpoint_address protocol new(protocol)| rpcin undef rpcout undef style new(style)|'document' transport transport_hook undef use 'literal' . endpoint_address => URI =over 4 Overrule the destination address. =back . protocol => URI|'HTTP' =over 4 Only the HTTP protocol is supported on the moment. The URI is the WSDL URI representation of the HTTP protocol. =back . rpcin => TYPE|CODE =over 4 Decode some received (incoming) SOAP-RPC structure into Perl data structures. See L. =back . rpcout => TYPE|CODE =over 4 Pack user values into an outgoing SOAP-RPC structure. See L. =back . style => 'document'|'rpc' . transport => CODE =over 4 The routine which will be used to exchange the data with the server. This code is usually created by L By default, a transporter compatible to the protocol is created. However, in most cases you want to reuse one (HTTP1.1) connection to a server. =back . transport_hook => CODE =over 4 Passed to L. Can be used to create off-line tests and last resort work-arounds. See the DETAILs chapter in the L manual page. =back . use => 'literal'|'encoded' =back $obj-EB(OPTIONS) =over 4 Prepare the routines which will decode the request and encode the answer, as will be run on the server. The L will connect these. Option --Default callback soap . callback => CODE . soap => XML::Compile::SOAP object =back =head2 Helpers $obj-EB(PROTOCOL, STYLE) =over 4 Returns a trueth value when the pair with URI of the PROTOCOL and processing STYLE (either C or C) is provided as soap binding. =back $obj-EB(ARGS, PORT-OP, BIND-OP) =over 4 =back $obj-EB(ARGS, PORT-OP, BIND-OP) =over 4 Collect the components of the message which are actually being used. =back $obj-EB(ARGS, 'CLIENT'|'SERVER', SOAP) =over 4 The ARGS is a HASH which contains options for L and for L. =back $obj-EB(MESSAGE, [NAMES]) =over 4 Collect the named message parts. If no names are specified, then all are all returned. =back =head1 SEE ALSO This module is part of XML-Compile-SOAP distribution version 0.77, built on August 15, 2008. Website: F All modules in this suite: L, L, L, L, L, L, L. Please post questions or ideas to the mailinglist at F For life contact with other developers, visit the C<#xml-compile> channel on C. =head1 LICENSE Copyrights 2007-2008 by Mark Overmeer. For other contributors see ChangeLog. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See F