Hi to all

I am very happy with Taverna (2.2.0) and congratulations to the Taverna
development team.

I have a question concerning XML attributes.

I've a service that accepts 2 dummy inputs, Taverna generates the
following XML that works fine:

<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";><soapenv:Body>

<ns1:ExecuteProcess_dummyprocess xmlns:ns1="http://foo";>

<input1 xmlns="">100</input1>
<input2 xmlns="">200</input2>

</ns1:ExecuteProcess_dummyprocess>

</soapenv:Body></soapenv:Envelope>

My question is:

How can I include an attribute in the input1 and input2 element ?!
Something like this:

<input1 xmlns="" lang="EN">100</input1>

The attribute doesn't need to be set by the user (I am using XMLSplitter
in the service to set the input1 and input2 value), it is something
default/standard (I know that XML Splitter doesn't support attributes,
but I don't need its support)

I've tried to change the types's XMLSchema that define input1/input2 from:

 <xsd:element maxOccurs="1" minOccurs="1" name="input1" type="xsd:integer"/>


into:


 <xsd:element maxOccurs="1" minOccurs="1" name="input1" type="xsd:integer">
        <xsd:attribute name="lang" type="xsd:string" fixed="EN"
use="required"/></xsd:element>


Hoping that the parser would "see" the attribute "lang" and would
include it with the default value.

I am not even certain if a parser would do such a thing (maybe it is a
silly idea ?!)

Who can give me a suggestion or indicate me how to do this attribute adding

Thanks

Jorge


                                

--------------------------------------------------------------------------------
Plymouth Marine Laboratory
 
Registered Office:
Prospect Place 
The Hoe
Plymouth  PL1 3DH
 
Website: www.pml.ac.uk
Registered Charity No. 1091222
PML is a company limited by guarantee
registered in England & Wales
company number 4178503

--------------------------------------------------------------------------------
This e-mail, its content and any file attachments are confidential.

If you have received this e-mail in error please do not copy, disclose it to 
any third party or use the contents or attachments in any way. Please notify 
the sender by replying to this e-mail or e-mail [email protected] and then 
delete the email without making any copies or using it in any other way.

The content of this message may contain personal views which are not the views 
of Plymouth Marine Laboratory unless specifically stated.

You are reminded that e-mail communications are not secure and may contain 
viruses. Plymouth Marine Laboratory accepts no liability for any loss or damage 
which may be caused by viruses.
--------------------------------------------------------------------------------

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
taverna-users mailing list
[email protected]
[email protected]
Web site: http://www.taverna.org.uk
Mailing lists: http://www.taverna.org.uk/about/contact-us/

Reply via email to