[jbosstools-issues] [JBoss JIRA] (JBIDE-13300) palette NPE for h:dataTable

Viacheslav Kabanovich (JIRA) jira-events at lists.jboss.org
Fri Dec 21 19:39:08 EST 2012


    [ https://issues.jboss.org/browse/JBIDE-13300?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12742952#comment-12742952 ] 

Viacheslav Kabanovich commented on JBIDE-13300:
-----------------------------------------------

Reproduced for Dynamic Web Project without JSF capabilities.

Wizard fails at loading properties of selected bean class for table items. Because project has no jsf nature, no XModel is returned (which is used to access its utilities in getting class properties), result is not checked for null, hence exception is thrown.
However, getting class properties does not need jsf capabilities, so that code can be revised to work with or without jsf nature.
As a minor additional improvement, if class is not set, there should be no further computations. If that had been done, the wizard would open and though throwing exceptions at selecting class value, still could be finished.
                
> palette NPE for h:dataTable
> ---------------------------
>
>                 Key: JBIDE-13300
>                 URL: https://issues.jboss.org/browse/JBIDE-13300
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: jsp/jsf/xml source editing
>            Reporter: Max Rydahl Andersen
>            Assignee: Viacheslav Kabanovich
>             Fix For: 4.1.0.Alpha1
>
>
> org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.NullPointerException)
> 	at org.eclipse.swt.SWT.error(SWT.java:4282)
> 	at org.eclipse.swt.SWT.error(SWT.java:4197)
> 	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:138)
> 	at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3938)
> 	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3615)
> 	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2701)
> 	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2665)
> 	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2499)
> 	at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:679)
> 	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
> 	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:668)
> 	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
> 	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:123)
> 	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
> 	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344)
> 	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:597)
> 	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
> 	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
> 	at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
> Caused by: java.lang.NullPointerException
> 	at org.jboss.tools.jsf.model.pv.JSFProjectsTree.getProjectsRoot(JSFProjectsTree.java:45)
> 	at org.jboss.tools.jsf.model.pv.JSFPromptingProvider.buildBean(JSFPromptingProvider.java:382)
> 	at org.jboss.tools.jsf.model.pv.JSFPromptingProvider.buildBeanProperties(JSFPromptingProvider.java:366)
> 	at org.jboss.tools.jsf.ui.wizard.palette.DataTableWizardPage.getAvailableProperties(DataTableWizardPage.java:388)
> 	at org.jboss.tools.jsf.ui.wizard.palette.DataTableWizardPage.access$0(DataTableWizardPage.java:383)
> 	at org.jboss.tools.jsf.ui.wizard.palette.DataTableWizardPage$XChildrenEditorImpl.updateBar(DataTableWizardPage.java:353)
> 	at org.jboss.tools.common.model.ui.objecteditor.XChildrenEditor.enableSelectionListener(XChildrenEditor.java:176)
> 	at org.jboss.tools.common.model.ui.objecteditor.XChildrenEditor.createControl(XChildrenEditor.java:84)
> 	at org.jboss.tools.jsf.ui.wizard.palette.DataTableWizardPage.fillGeneralOption(DataTableWizardPage.java:209)
> 	at org.jboss.tools.jsf.ui.wizard.palette.DataTableWizardPage.showAttributes(DataTableWizardPage.java:146)
> 	at org.jboss.tools.jsf.ui.wizard.palette.DataTableWizardPage.createControl(DataTableWizardPage.java:101)
> 	at org.eclipse.jface.wizard.Wizard.createPageControls(Wizard.java:174)
> 	at org.eclipse.jface.wizard.WizardDialog.createPageControls(WizardDialog.java:736)
> 	at org.eclipse.jface.wizard.WizardDialog.createContents(WizardDialog.java:608)
> 	at org.eclipse.jface.window.Window.create(Window.java:431)
> 	at org.eclipse.jface.dialogs.Dialog.create(Dialog.java:1089)
> 	at org.jboss.tools.common.model.ui.editors.dnd.DropWizardDialog.create(DropWizardDialog.java:95)
> 	at org.eclipse.jface.window.Window.open(Window.java:790)
> 	at org.jboss.tools.common.model.ui.editors.dnd.DefaultDropCommand.execute(DefaultDropCommand.java:105)
> 	at org.jboss.tools.jst.jsp.jspeditor.JSPTextEditor$4.run(JSPTextEditor.java:755)
> 	at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
> 	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:135)
> 	... 22 more

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jbosstools-issues mailing list