WSO2::WSF::WSClient - Perl interface to consume Web services using WSF/C.
use WSO2::WSF::WSClient; my $client = new WSO2::WSF::WSClient(); my $client = new WSO2::WSF::WSClient( { WSCLIENT_OPTIONS } ); my $response = $client->request( { 'payload' => 'your payload in XML' } ); my $message = new WSO2::WSF::WSMessage( { WSMESSAGE_OPTIONS } ); my $response = $client->request( $message );
This module provide a simple interface in Perl to WSO2 WSF/C. It's based on Apache Axis2/C project and bundle several other related projects (Sandesha2/C, Rampart/C, Savan ...) in to a single distribution.
You could give options to WSClient contructor when creating a new client or you could construct a WSMessage object and pass it to the request method after creating the client.
This should hold the absolute path name where you have installed WSF/C. If you don't provide this, WSF/Perl look for an environment variable called WSFC_HOME. If it cannot find the location where WSF/C is installed it'll exit giving an error message.
Valid options, 'TRUE', 'FALSE', '1.1', '1.2'. Default value is 'TRUE'. If this is set SOAP bindings will be used. Otherwise REST style invocation will be used along with the method given by HTTPMethod option. By default SOAP 1.2 message style will be used.
Valid options, 'TRUE', 'FALSE'. Indicates whether the attachments should be sent MTOM optimized or not. If 'TRUE', the attachments will be sent out of the SOAP message, optimized, with MIME headers in place. If 'FALSE', attachments will be sent within the SOAP payload, as base64 binary.
Specifies which HTTP method to use. Valid values are 'GET', 'get', 'POST' and 'post'. Defaults to 'POST'.
Controls whether XOP elements in a response with MTOM are resolved into the logically equivalent straight XML infoset or not. If 'TRUE', the member variable "attachments" of the message returned as a result of the calling request method would be set. If 'FALSE', the binary content will be present in the response payload in base64 format.
Tell whether to use WS-Addressing. Valid values are 'TRUE', 'FALSE', '1.0' and 'submission'. If 'submission' is specified 'action' must be present.
Should be a WSPolicy object.
WSSecurityToken object which contain the security related options.
This is an instance method. You could either give the payload as an XML string or you could construct a WSMessage object and give that.
Look at WSO2::WSF::WSMessage for how to construct a WSMessage object with various message related options.
Mailing list, bug tracker, svn info can be found on the project web site at http://wso2.org/projects/wsf/perl
WSO2 WSF/Perl Team
Copyright (C) 2007 by WSO2
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
2 POD Errors
The following errors were encountered while parsing the POD:
You forgot a '=back' before '=head1'
To install WSO2::WSF::C, copy and paste the appropriate command in to your terminal.
cpanm
cpanm WSO2::WSF::C
CPAN shell
perl -MCPAN -e shell install WSO2::WSF::C
For more information on module installation, please visit the detailed CPAN module installation guide.