Thank you for the detail explanation. Everything is clear now, in the end I've decided to drop the "anyType" declaration for a practical motive.
The WPS protocol defines a type of response called ComplexType, that can be XML or a base64 string (image). If I implement the anyType I will always have the <outputResults></outputResults> if I've a XML or a base64 string, the user will always have to get rid of the <outputResults></outputResults> If I don't declare anything, I will get the base64 string that it can be easily converted to byte format and display or passed to another webservice, if the reply is XML then it is relatively easy to use the Xpath plugin to get the desired XML content and send it to another service :) I am more or less finished with WPS implementation and I am starting to write documentation explaining the use of Taverna for geospatial operations (WPS). Thank you for the help Jorge On 20/10/10 14:05, Stian Soiland-Reyes wrote: > On Tue, Oct 12, 2010 at 18:16, Jorge de Jesus <[email protected]> wrote: >> <element name="outputResult" maxOccurs="1" minOccurs="1" >> type="wps:dummyType"> > .. > >> <complexType name="dummyType"> >> <sequence> >> <any namespace="##any" processContents="skip" minOccurs="1" >> maxOccurs="1"></any> >> The outputResult output from the splitter outputs something like: >> >> <outputResult><a><b/></a><outputResult> >> >> I would except for the splitter to return just "<a></b></a>", since its >> the content to the outputResult > No, you'll unfortunately get the containing element as well, as the > type is not guaranteed to contain only a single element.. So say the > dummyType was instead: > > <complexType name="dummyType"> > <sequence> > <element name="fish" ... /> > <element name="soup" ... /> > </sequence> > </complexType> > > In which case you could get from the service: > > > <ExecuteProcessResponse> > <textResult>asdasd</textResult> > <outputResult> > <fish>sd</fish> > <soup>sdfsdf</soup> > </outputResult> > </ExecuteProcessResponse> > > - the XML splitter would then on the "outputResult" port output only > give <outputResult><fish>..</fish><soup>..</soup></outputResult> - so > that it is still valid XML (potentially going to other XML splitters > or other web services) > > In fact - on the input to the XML splitter - the outer element is ignored. > > I assume in the workflow above you are not able to add another output > XML splitter to the ExecuteProcess_Returner_Process_Output splitter, > perhaps Taverna gets confused by xsd:any.. > > > Using your current schema, you might want to use the XPath plugin > instead - where you can easily select the 'any' element below > <outputResult>. To install the XPath plugin - go to Advanced -> > Updates and plugins -> Find new plugins and look under 'Prototype > plugins'. > > Add an XPath parser from the 'Local services' folder, and in the > wizard paste an example XML from your service before you make the > element selection. > > -------------------------------------------------------------------------------- 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. -------------------------------------------------------------------------------- ------------------------------------------------------------------------------ Nokia and AT&T present the 2010 Calling All Innovators-North America contest Create new apps & games for the Nokia N8 for consumers in U.S. and Canada $10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store http://p.sf.net/sfu/nokia-dev2dev _______________________________________________ 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/
