krypt-lynx / wsdl2objc

Automatically exported from code.google.com/p/wsdl2objc
MIT License
0 stars 0 forks source link

Code generated for service with no input parameters does not compile #45

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
See the attached WSDL file which is for a web service that returns active
tide/weather stations for which NOAA will return data.  (Web site is
http://opendap.co-ops.nos.noaa.gov/axis/)  The web service does not have
any input parameters.

Misgenerated code from "ActiveStationsService.m":

- (ActiveStationsSoapBindingResponse *)getActiveStationsUsing
{
    return [self
performSynchronousOperation:[[(ActiveStationsSoapBinding_getActiveStations*)[Act
iveStationsSoapBinding_getActiveStations
alloc] initWithBinding:self delegate:self
                                                                                            ] autorelease]];
}
- (void)getActiveStationsAsyncUsing
delegate:(id<ActiveStationsSoapBindingResponseDelegate>)responseDelegate
{
    [self performAsynchronousOperation:
[[(ActiveStationsSoapBinding_getActiveStations*)[ActiveStationsSoapBinding_getAc
tiveStations
alloc] initWithBinding:self delegate:responseDelegate
                                                                                             ] autorelease]];
}

Note the second function is missing a parameter after the first keyword.

Original issue reported on code.google.com by tom.d...@gmail.com on 14 Oct 2009 at 2:00

Attachments:

GoogleCodeExporter commented 9 years ago
Yep it doesn't like it when there are no parameters.
As a workaround, change the functions like this:

- (ActiveStationsSoapBindingResponse *)getActiveStations
{
    return [self
performSynchronousOperation:[[(ActiveStationsSoapBinding_getActiveStations*)[Act
iveStationsSoapBinding_getActiveStations
alloc] initWithBinding:self delegate:self] autorelease]];
}
- 
(void)getActiveStationsAsyncWithDelegate:(id<ActiveStationsSoapBindingResponseDe
legate>)responseDelegate
{
    [self performAsynchronousOperation:
[[(ActiveStationsSoapBinding_getActiveStations*)[ActiveStationsSoapBinding_getAc
tiveStations
alloc] initWithBinding:self delegate:responseDelegate ] autorelease]];
}

Original comment by hasse...@gmail.com on 14 Oct 2009 at 8:21

GoogleCodeExporter commented 9 years ago
I was getting the same errors, which were solved using the same solution. I am 
getting the data for the 
service requests which does not require any parameter passing,but for the 
services which requires parameter 
passing i am getting the following error:
2009-10-30 18:47:33.490 TestSoap[3178:20b] ResponseError:
Error Domain=lostpetusawebservice_wsdlBindingResponseHTTP Code=1 
UserInfo=0xd81940 "Unexpected 
response MIME type to SOAP call:text/html"
 Tom, did you faced similar problem?can you please give me the code snippet for calling the service request 
which require parameter passing?
Thanks in advance.

Original comment by rajnish.khatri@gmail.com on 30 Oct 2009 at 1:20

GoogleCodeExporter commented 9 years ago
i have this same problem:/ any solution?

Original comment by P.Grabow...@gmail.com on 30 Apr 2012 at 9:30