There are a few things I noticed immediately.
1. Your missing the famous line
<?xml version="1.0" encoding="utf-8"?>
>From the top of the wsdl file.
2. You are missing the services section in the wsdl. You need something
like this:
...
<service name="GuideService">
<port binding="tns:GuideServicesImplBinding" name="GuideServicesImpl">
<soap:address
location="http://localhost:8080/axis/services/GuideService"/>
</port>
</service>
...
Put it straight after the binding section, but before
</wsdl:definitions>
3. You have multiple <schema> tags. I'm not sure that's allowed (but it
might be). Normally you would import the other schemas as separate files
with their own namespaces. (Each has a targetNameSpace, and it might
confuse the generator, since its probably only expecting one
targetNameSpace).
4. I think the targetNameSpaces are further screwed up. I broke out each
schema into a separate file, imported each file into the wsdl and
managed to generate a web service, by adding in each operation one by
one (I started with them all commented out in the port and binding
sections, except for the first operation, deleteProgramReminders). All
went well until I reached getTVListings. That's where I first hit the
null pointer exception.
Sorry, but I haven't got the time to investigate further.
Good luck,
-jeff
-----Original Message-----
From: samanth marisetty [mailto:[EMAIL PROTECTED]
Sent: Friday, November 09, 2007 12:03 PM
To: [email protected]
Subject: Re: axis wsdl2java nullPointerException
Hi,
Thanks for your suggestions.. I did validate the wsdl and it
validated succesfully. I have attached my wsdl please let me know what
could be wrong...
Thanks,
Samanth Marisetty.
On Nov 9, 2007 11:45 AM, Walker, Jeff <[EMAIL PROTECTED]> wrote:
> Your wsdl is screwed up.
> You could post it here, and maybe someone will read it and give you
some
> hints.
> Or, you could do what I always do, comment out all the operations
except
> the simplest, and try that. Keep adding in another operation until you
> find the one that cause the problem. Then edit the request and
response
> parameters until you learn which piece of schema is probably causing
> your issue.
> -jeff
>
>
>
> -----Original Message-----
> From: samanth marisetty [mailto:[EMAIL PROTECTED]
> Sent: Friday, November 09, 2007 11:38 AM
> To: [email protected]
> Subject: axis wsdl2java nullPointerException
>
> Hi,
> When I use the axis wsdl2java tool I get this error..
> java.lang.NullPointerException
> at
>
org.apache.axis.wsdl.toJava.JavaBeanHelperWriter.getAsFieldName(JavaBean
> HelperWriter.java:435)
> at
>
org.apache.axis.wsdl.toJava.JavaBeanHelperWriter.writeMetaData(JavaBeanH
> elperWriter.java:325)
> at
>
org.apache.axis.wsdl.toJava.JavaBeanHelperWriter.writeFileBody(JavaBeanH
> elperWriter.java:183)
> at
> org.apache.axis.wsdl.toJava.JavaWriter.generate(JavaWriter.java:127)
> at
>
org.apache.axis.wsdl.toJava.JavaBeanWriter.writeFileBody(JavaBeanWriter.
> java:257)
> at
> org.apache.axis.wsdl.toJava.JavaWriter.generate(JavaWriter.java:127)
> at
>
org.apache.axis.wsdl.toJava.JavaBeanWriter.generate(JavaBeanWriter.java:
> 1405)
> at
>
org.apache.axis.wsdl.toJava.JavaTypeWriter.generate(JavaTypeWriter.java:
> 113)
> at
>
org.apache.axis.wsdl.toJava.JavaGeneratorFactory$Writers.generate(JavaGe
> neratorFactory.java:421)
> at
> org.apache.axis.wsdl.gen.Parser.generateTypes(Parser.java:547)
> at org.apache.axis.wsdl.gen.Parser.generate(Parser.java:432)
> at org.apache.axis.wsdl.gen.Parser.access$000(Parser.java:45)
> at
> org.apache.axis.wsdl.gen.Parser$WSDLRunnable.run(Parser.java:362)
> at java.lang.Thread.run(Unknown Source)
>
> Could some body please explain me why it occurs..
> I am new to web services so I am not sure what is wrong with the
> wsdl..
>
> Is there a way I could know where exacty the NPE is caused?
>
> Thanks,
> Samanth Marisetty.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]