This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 123071 - NullPointerException at org.netbeans.modules.websvc.core.MethodGenerator.generateMethod
Summary: NullPointerException at org.netbeans.modules.websvc.core.MethodGenerator.gene...
Status: RESOLVED FIXED
Alias: None
Product: webservices
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P4 blocker (vote)
Assignee: Milan Kuchtiak
URL: http://statistics.netbeans.org/except...
Keywords:
Depends on:
Blocks:
 
Reported: 2007-11-29 15:55 UTC by sanne
Modified: 2008-11-19 13:58 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 13361


Attachments
stacktrace (857 bytes, text/plain)
2007-11-29 15:55 UTC, sanne
Details

Note You need to log in before you can comment on or make changes to this bug.
Description sanne 2007-11-29 15:55:23 UTC
Build: NetBeans IDE 6.0 RC2 (Build 200711201000)
VM: Java HotSpot(TM) Client VM, 1.5.0_07-b03
OS: Windows XP, 5.1, x86

User Comments: 
Steps that caused the error:

1. Make web project
2. Make XSD with 2 simple types string named request and reply
3. Make WSDL based on XSD
4. Create service from WSDL
5. Add two complex types to WSDL
6. Change messages from simple types to complex types

This gave a null pointer.
Comment 1 sanne 2007-11-29 15:55:27 UTC
Created attachment 53676 [details]
stacktrace
Comment 2 sanne 2007-11-30 22:55:06 UTC
Just to make sure, the exception was caused by the fact that I changed the messages type so that it pointed directly to
a complex type instead of an element with a complex type. The WSDL wizzard protects against this scenario, stating that
the message type should point to an element. But applying the editor after the wizzard does not prevent one making this
mistake, resulting in the exception.   
Comment 3 sanne 2007-11-30 23:06:54 UTC
Errr. and 5. should be add complex types to XSD.
Comment 4 Lukas Jungmann 2008-04-14 17:17:31 UTC
moving opened issues where TM != dev to TM=TBD
Comment 5 Milan Kuchtiak 2008-09-22 16:47:28 UTC
Should be fixed for 6.5.
Comment 6 Milan Kuchtiak 2008-11-19 13:58:31 UTC
The Add Operation action was likely called, which throws this NPE.

The better would be to call Refresh Service action on service node after wsdl changes.
In this case, the wsimport would tell user that massages cannot reference schema types, but elements, in
document/literal binding type.

Nevertheless, the NPE was fixed already. It was thrown, since the implementation class created for "WS from WSDL" was
changed after web method was added.