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 61072

Summary: Cannot edit CMP finder methods
Product: javaee Reporter: Pavel Fiala <pfiala>
Component: EJB ProjectAssignee: Pavel Fiala <pfiala>
Status: VERIFIED FIXED    
Severity: blocker    
Priority: P1    
Version: 5.x   
Hardware: PC   
OS: Windows XP   
Issue Type: DEFECT Exception Reporter:

Description Pavel Fiala 2005-07-18 08:25:33 UTC
Let's have EJB Module with CMP Entity Bean and at least one CMP finder method
Try to edit the finder method using visual DD editor. Even if no change is done,
an exception is thrown after confirming the Edit dialog:
java.lang.ArrayStoreException
        at java.lang.System.arraycopy(Native Method)
        at java.util.ArrayList.toArray(ArrayList.java:305)
        at
org.netbeans.mdr.storagemodel.AttrCollection.toArray(AttrCollection.java:233)
        at
org.netbeans.mdr.handlers.AttrImmutCollWrapper.toArray(AttrImmutCollWrapper.java:128)
        at
org.netbeans.modules.javacore.jmiimpl.javamodel.LightAttrList.toArray(LightAttrList.java:309)
        at
org.netbeans.modules.j2ee.ejbjarproject.ui.customizer.QueryCustomizer.updateQueryMethod(QueryCustomizer.java:84)
        at
org.netbeans.modules.j2ee.ejbjarproject.ui.customizer.QueryCustomizer.showDialog(QueryCustomizer.java:72)
        at
org.netbeans.modules.j2ee.ejbjarproject.ui.customizer.QueryCustomizer.showFinderCustomizer(QueryCustomizer.java:52)
        at
org.netbeans.modules.j2ee.ddloaders.multiview.FinderMethodsTableModel.editRow(FinderMethodsTableModel.java:46)
        at
org.netbeans.modules.j2ee.ddloaders.multiview.FinderMethodsNode$1.editCell(FinderMethodsNode.java:37)
        at
org.netbeans.modules.j2ee.ddloaders.multiview.InnerTablePanel$2.actionPerformed(InnerTablePanel.java:55)
        at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
        at
javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
        at
javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
        at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
        at
javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:234)
        at java.awt.Component.processMouseEvent(Component.java:5488)
        at javax.swing.JComponent.processMouseEvent(JComponent.java:3126)
        at java.awt.Component.processEvent(Component.java:5253)
        at java.awt.Container.processEvent(Container.java:1966)
        at java.awt.Component.dispatchEventImpl(Component.java:3955)
        at java.awt.Container.dispatchEventImpl(Container.java:2024)
        at java.awt.Component.dispatchEvent(Component.java:3803)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
        at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
        at java.awt.Container.dispatchEventImpl(Container.java:2010)
        at java.awt.Window.dispatchEventImpl(Window.java:1774)
        at java.awt.Component.dispatchEvent(Component.java:3803)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
[catch] at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
        at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
Comment 1 Pavel Fiala 2005-07-18 08:40:25 UTC
The exception occurs if the finder method has parameters
Comment 3 Pavel Fiala 2005-07-18 15:20:31 UTC
*** Issue 60537 has been marked as a duplicate of this issue. ***
Comment 4 Jan Horvath 2006-07-19 17:08:46 UTC
v