You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Emma Johansson <Em...@su.eip.ericsson.se> on 2002/11/11 14:33:43 UTC

XML instead of WSDL?

Hi!

I'm wondering about WSDL and XML. Is it possible to use an XML schema
instead of the WSDL document or a combination of both when creating a
web service using Axis?

I've already created a web service by using the Java2wsdl2Java tool, but
I want to make the wsdl document more flexible. Just like XML where you
have the opportunity to choose if the entry should contain exactly one
("") element, 0 or 1 element (?), at least one element (+) or zero or
more elements (*) in the DTD.

If so, can you please tell me where to find information about this.

Regards,
Emma


Re: XML instead of WSDL?

Posted by James Yegerlehner <ja...@kamiak.com>.
----- Original Message -----
From: "Emma Johansson" <Em...@su.eip.ericsson.se>
To: <ax...@xml.apache.org>
Sent: Monday, November 11, 2002 6:33 AM
Subject: XML instead of WSDL?
> Hi!

Hi Emma-

> I'm wondering about WSDL and XML. Is it possible to use an XML schema
> instead of the WSDL document or a combination of both when creating a
> web service using Axis?

WSDL already uses XML Schema to specify the types of the message parts
involved in a web service.  The "types" element of the WSDL document
contains a schema which can contain any types you like.

Regards,
------------
James Yegerlehner
Omniopera: XML Schema and WSDL Authoring Software
http://www.omniopera.com


Re: XML instead of WSDL?

Posted by James Black <jb...@ieee.org>.
Emma Johansson wrote:

>I'm wondering about WSDL and XML. Is it possible to use an XML schema
>instead of the WSDL document or a combination of both when creating a
>web service using Axis?
>
  WSDL is an XML format, just a specific one for web services.

>I've already created a web service by using the Java2wsdl2Java tool, but
>I want to make the wsdl document more flexible. Just like XML where you
>have the opportunity to choose if the entry should contain exactly one
>("") element, 0 or 1 element (?), at least one element (+) or zero or
>more elements (*) in the DTD.
>
  You can add features to your wsdl file (change it), but unless the 
tool you use to create the stubs knows what they are it will not matter 
(the changes will be ignored).




resources m$_interop service_parameters

Posted by Olivier Fauchon <ol...@labocom.com>.
Hi,

It seems this M.L. is the best source of  informations over the net ..
I'm new to SOAP/AXIS/this ML, so please excuse me for the following 
stupid questions :-)

1. Resources

I'm looking for detailed case study of services using custom 
types/javabean , from AXIS server to MS SOAP Toolkit clients .
If someone has urls ... thx

2. MS Clients.

I have to code excel macros that get informations from my AXIS server 
(i'm not M$ addict, but customers are).
I had a little attempt, which was successfull...
But to retreive my datas on the MS Client using MS SOAP Toolkit 3, i had 
to parse DOM result (to get back my custom types)

I guess (hope) there's a simpler way to directly get my objects on the 
client (i would like to get my custom types).
So if someone is experienced, please give me more detailed informations.

3.  Services Parameters

There was some thread on  passing parameters to services ... from that i 
 add the following line :

 <service name="BaseService" provider="java:RPC">
  <parameter name="hereismyparameter" value="itsvalue"/>                
<!--   THIS IS THE PARAM I WANT TO USE -->
  <parameter name="allowedMethods" value="*"/>
  <parameter name="className" 
value="com.labocom.apps.basegeneric.export.soap.v1.BaseService"/>
  <namespace>http://www.labocom.com/BaseService</namespace>
 </service>

... My question is ... how do i get the parameter from within the 
published class "BaseService" ... as this class don't even extends 
anything (like
servlet would do ) ...


Thanks a lot

Olivier Fauchon
Labocom Informatique
labocom.com











Re: XML instead of WSDL?

Posted by James Black <jb...@ieee.org>.
Emma Johansson wrote:

> I would like to send different parameters to the server. These
> parameters should be able to have several values.
> I mean, my program should modify a register that contains name, phone
> number, email, address etc. As some people have more than one email
> address they should be able to fill them in, but the program should
> accept this element to be empty as well.
> Can you please tell me how to do.

  Some here will disagree with my thought, but you may want to just send
your data to the server as an XML string. This will allow you to use
several email addresses, not put in the empty values into the xml file,
etc. Otherwise you are sending arrays of strings for the attributes that
can be multiple.

  I use java2wsdl to generate the wsdl file and wsdl2java to create my
stubs. <g>


Re: XML instead of WSDL?

Posted by Emma Johansson <Em...@su.eip.ericsson.se>.
I would like to send different parameters to the server. These parameters
should be able to have several values.
I mean, my program should modify a register that contains name, phone
number, email, address etc. As some people have more than one email address
they should be able to fill them in, but the program should accept this
element to be empty as well.
Can you please tell me how to do.

"types" seems to be an empty element.
My wsdl looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="urn:ldapTest"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:apachesoap="http://xml.apache.org/xml-soap"
    xmlns:impl="urn:ldapTest" xmlns:intf="urn:ldapTest"
    xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:types/>
<wsdl:message name="addRequest"> ... </wsdl:message>
<wsdl:portType name="LdapTest"> ... </wsdl:portType>
<wsdl:binding name="ldapTestSoapBinding" type="intf:LdapTest"> ...
</wsdl:binding>
<wsdl:service name="LdapTestService"> ... </wsdl:service>
</wsdl:definitions>


Regards,
Emma

Emma Johansson wrote:

> Hi!
>
> I'm wondering about WSDL and XML. Is it possible to use an XML schema
> instead of the WSDL document or a combination of both when creating a
> web service using Axis?
>
> I've already created a web service by using the Java2wsdl2Java tool, but
> I want to make the wsdl document more flexible. Just like XML where you
> have the opportunity to choose if the entry should contain exactly one
> ("") element, 0 or 1 element (?), at least one element (+) or zero or
> more elements (*) in the DTD.
>
> If so, can you please tell me where to find information about this.
>
> Regards,
> Emma