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 70281 - IllegalArgumentException is thrown when CMP beans are generated
Summary: IllegalArgumentException is thrown when CMP beans are generated
Status: VERIFIED FIXED
Alias: None
Product: xml
Classification: Unclassified
Component: Code (show other bugs)
Version: 5.x
Hardware: PC All
: P2 blocker (vote)
Assignee: Marek Fukala
URL:
Keywords:
: 70245 (view as bug list)
Depends on:
Blocks: 70376
  Show dependency tree
 
Reported: 2005-12-12 15:55 UTC by Petr Blaha
Modified: 2005-12-19 10:17 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
stack trace (1.04 KB, text/plain)
2005-12-12 15:56 UTC, Petr Blaha
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Petr Blaha 2005-12-12 15:55:18 UTC
[build 20051211]
Steps:
1) create J2EE application
2) generate CMP bean from database
ERROR: java.lang.IllegalArgumentException: getParent() called for DE
(30042642)["..." (content) <5927-5927> ''] w ... is thrown
Comment 1 Petr Blaha 2005-12-12 15:56:44 UTC
Created attachment 27752 [details]
stack trace
Comment 2 Marek Fukala 2005-12-12 16:40:59 UTC
The exception is relatively harmless (affects only the XML navigator) thought it
is very visible to user. I am decreasing to P2, I will fix it to 5.0. The
problem is caused by my recent changes in the document model infrastructure. All
tests passes, but apparently not everything is covered :-(.
Comment 3 Marek Fukala 2005-12-13 15:20:22 UTC
fixed in trunk - QE, please verify and Petre, please review the code change.

The problem was caused by an attempt to remove an already removed element from
the document model. Fixed by testing whether the element has already been
removed, and if so do not try it again.

Checking in
xml/tageditorsupport/src/org/netbeans/modules/editor/structure/api/DocumentModel.java;
/cvs/xml/tageditorsupport/src/org/netbeans/modules/editor/structure/api/DocumentModel.java,v
 <--  DocumentModel.java
new revision: 1.25; previous revision: 1.24
done
Checking in
xml/text-edit/src/org/netbeans/modules/xml/text/structure/XMLDocumentModelProvider.java;
/cvs/xml/text-edit/src/org/netbeans/modules/xml/text/structure/XMLDocumentModelProvider.java,v
 <--  XMLDocumentModelProvider.java
new revision: 1.17; previous revision: 1.16
done
Comment 4 Marek Fukala 2005-12-13 15:22:47 UTC
Petre, can you review the fix?
Comment 5 Petr Pisl 2005-12-13 15:29:56 UTC
I'm OK with the fix.
Comment 6 Petr Blaha 2005-12-14 09:24:14 UTC
The fix was verified in trunk daily build 20051213. Fix can be merge in NB 5.0
branch.
Comment 7 Jiri Prox 2005-12-14 10:30:42 UTC
*** Issue 70245 has been marked as a duplicate of this issue. ***
Comment 8 Jaromir Uhrik 2005-12-14 20:48:59 UTC
Although this issue is Q-build stopper we have no special Q-build branch. The
fix must go just to trunk and release50 branch.
Comment 9 Marek Fukala 2005-12-15 12:50:33 UTC
fixes merged to release50 branch.
Comment 10 Petr Blaha 2005-12-19 10:17:34 UTC
[build 20051218 release50 branch]