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 94793 - followup on cut/copy/paste for dataproviders in outline
Summary: followup on cut/copy/paste for dataproviders in outline
Status: STARTED
Alias: None
Product: obsolete
Classification: Unclassified
Component: visualweb (show other bugs)
Version: 5.x
Hardware: All Windows XP
: P4 blocker (vote)
Assignee: _ sandipchitale
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-02-06 21:02 UTC by bugbridge
Modified: 2007-10-31 23:11 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description bugbridge 2007-02-06 21:02:12 UTC
Original status: 5-Cause Known; Suggested Status: NEW

Original Target Release: shortfin_dev; Suggested Target Milestone : 5.5


Original submitter: sjangity

Description:
Build 061101_1, NB 5.5 FCS, WinXP
EE5/JDK 1.6.0

This is a followup for 6463757.

- In a ee5 project, drop a database table (eg. Product) onto the SessionBean1
node in Outline
- On productDataProvider node issue 'Cut' context menu operation
- Open ctxt menu on SessionBean1 node and hit 'Paste'
> no new node is created

Evaluation:
It wrongly shows the possibility to paste, the paste should be disabled in that
case. Investigating.
The issue is in insync, where the node is implemented.

Evaluation (Entry 2):
IN=102988. Fixed.

Evaluation (Entry 3):
The last issue (see comments) is only when trying to paste on the same parent node.

The problem is that linveUnit.canMoveBean returns true for the bean which is
already under the parent.
(DesignBeanNode, in the createPasteTypes method.
Either that should be fixed, or additional check needs to be added. Passing to
insync, this is not gonna be fixed for FCS. Passing to insync, to deal with it
later.
Comment 1 _ sandipchitale 2007-10-22 20:46:23 UTC
Actually I am getting the following NPE when I drop a database table on SessionBean. Assigning to John for further
investigation.

java.lang.NullPointerException
	at sun.misc.URLClassPath.<init>(URLClassPath.java:94)
	at sun.misc.URLClassPath.<init>(URLClassPath.java:104)
	at java.net.URLClassLoader.<init>(URLClassLoader.java:88)
	at java.net.FactoryURLClassLoader.<init>(URLClassLoader.java:561)
	at java.net.URLClassLoader$5.run(URLClassLoader.java:520)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.newInstance(URLClassLoader.java:517)
	at
org.netbeans.modules.visualweb.dataconnectivity.sql.DesignTimeDataSource.getDriverClassLoader(DesignTimeDataSource.java:772)
	at org.netbeans.modules.visualweb.dataconnectivity.sql.DesignTimeDataSource.loadDriver(DesignTimeDataSource.java:756)
	at org.netbeans.modules.visualweb.dataconnectivity.sql.DesignTimeDataSource.getConnection(DesignTimeDataSource.java:258)
	at org.netbeans.modules.visualweb.dataconnectivity.sql.DesignTimeDataSource.getConnection(DesignTimeDataSource.java:240)
	at
org.netbeans.modules.visualweb.dataconnectivity.sql.DatabaseMetaDataHelper.getConnection(DatabaseMetaDataHelper.java:458)
	at org.netbeans.modules.visualweb.dataconnectivity.sql.DatabaseMetaDataHelper.getMetaData(DatabaseMetaDataHelper.java:465)
	at
org.netbeans.modules.visualweb.dataconnectivity.sql.DatabaseMetaDataHelper.getTablesInternal(DatabaseMetaDataHelper.java:380)
	at
org.netbeans.modules.visualweb.dataconnectivity.sql.DatabaseMetaDataHelper.getTableMetaData(DatabaseMetaDataHelper.java:109)
	at
org.netbeans.modules.visualweb.dataconnectivity.sql.DatabaseMetaDataHelper.getTableOrViewMetaData(DatabaseMetaDataHelper.java:152)
	at
org.netbeans.modules.visualweb.dataconnectivity.sql.DatabaseMetaDataHelper.getNoSchemaName(DatabaseMetaDataHelper.java:213)
	at
org.netbeans.modules.visualweb.dataconnectivity.explorer.RowSetBeanCreateInfoSet.setDataSourceInfo(RowSetBeanCreateInfoSet.java:114)
	at
org.netbeans.modules.visualweb.dataconnectivity.model.DatasourceTransferManager$DatasourceBeanCreateInfoSet.beansCreatedSetup(DatasourceTransferManager.java:241)
	at org.netbeans.modules.visualweb.insync.live.DesignBeanNode$BeanCreateInfoSetPasteType.paste(DesignBeanNode.java:839)
	at org.openide.explorer.view.DragDropUtilities.performPaste(DragDropUtilities.java:197)
	at org.openide.explorer.view.TreeViewDropSupport.drop(TreeViewDropSupport.java:769)
	at java.awt.dnd.DropTarget.drop(DropTarget.java:430)
	at sun.awt.dnd.SunDropTargetContextPeer.processDropMessage(SunDropTargetContextPeer.java:500)
	at sun.awt.dnd.SunDropTargetContextPeer.access$800(SunDropTargetContextPeer.java:53)
	at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchDropEvent(SunDropTargetContextPeer.java:812)
	at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchEvent(SunDropTargetContextPeer.java:736)
	at sun.awt.dnd.SunDropTargetEvent.dispatch(SunDropTargetEvent.java:29)
	at java.awt.Component.dispatchEventImpl(Component.java:3826)
	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.processDropTargetEvent(Container.java:3963)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3817)
	at java.awt.Container.dispatchEventImpl(Container.java:2010)
	at java.awt.Window.dispatchEventImpl(Window.java:1778)
	at java.awt.Component.dispatchEvent(Component.java:3803)
[catch] at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
	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 2 John Baker 2007-10-22 21:27:27 UTC
I'll have to revert my last change until the getUrl() in the db module is fixed
Comment 3 John Baker 2007-10-22 21:34:55 UTC
Done, please update dataconnectivity and build.  Drag and drop of table onto Session Bean is working again
Comment 4 John Baker 2007-10-24 23:46:14 UTC
the NPE has been resolved
Comment 5 John Baker 2007-10-25 01:38:27 UTC
after selecting the dataprovider then  choosing cut and invoking "paste" on the SessionBean1 node "paste" is
correctly disabled

However, if the Page1 node is selected then "paste" is still disabled.

I would expect "paste" to be enabled if pasting to another node.

Note, instead of choosing "cut" I choose "copy" then paste is enabled for another node
Comment 6 _ sandipchitale 2007-10-31 23:11:59 UTC
Reducing the priority as there is workaround to copy/paste the Dataprovider and then deleting it from the SessionBean1.