[Jolie-devel] Webservice SOAP-XML handling
A service-oriented programming language.
Brought to you by:
fmontesi
From: Matthias D. W. <mwa...@ya...> - 2013-11-22 15:37:34
|
Hi devs, I have another interesting issue in respect to SOAP. Webservice: http://wsf.cdyne.com/WeatherWS/Weather.asmx?WSDL The type declaration of "WeatherReturnType" (for call GetCityWeatherByZIP()) determined by wsdl2jolie (which is correct if you have a look at the WSDL file - http://wsf.cdyne.com/WeatherWS/Weather.asmx?WSDL!): > type WeatherReturnType:void { > .WeatherID:int > .Description?:string > .State?:string > .ResponseText?:string > .RelativeHumidity?:string > .WindChill?:string > .Temperature?:string > .Remarks?:string > .Visibility?:string > .Pressure?:string > .Success:bool > .WeatherStationCity?:string > .Wind?:string > .City?:string > } A possible result of GetCityWeatherByZIP(): > <WeatherReturn><Success>true</Success><ResponseText>City > Found</ResponseText><State>NY</State><City>New > York</City><WeatherStationCity>White > Plains</WeatherStationCity><WeatherID>14</WeatherID><Description>Cloudy</Description><Temperature>46</Temperature><RelativeHumidity>89</RelativeHumidity><Wind>S3</Wind><Pressure>30.21F</Pressure><Visibility/><WindChill/><Remarks/></WeatherReturn> Jolie blames about the <.../> since it recognizes them as VOIDs not strings: > WARNING: [weatherServiceCallerNYC.ol] Received message TypeMismatch > (GetCityWeatherByZIP@WeatherSoap): Invalid native type for node > #Message.GetCityWeatherByZIPResult: expected VOID, found java.lang.String I have tried to look into the code but there does not seem to be an easy solution. As a workaround I can change the datatype of the "<.../>" fields in the type stucture to VOID - then everything works. Does there exist something different? Cheers, Matthias |