Project: JDT
Bug 62508 [Externalize] Edit fails when key or value is null [nls] [refactoring]
Reported: 2004-05-17 13:31:05 | Status: resolved fixed

N20040517 on WXP Externalize any source which can be externalized, e.g. ExternalizeWizardPage.java Select a row which has a null key and/or value. This is common when you have asked to ignore/skip these items. You will get the following: java.lang.NullPointerException at java.lang.Throwable.<init>(Throwable.java) at java.lang.Throwable.<init>(Throwable.java) at java.lang.NullPointerException.<init>(NullPointerException.java:60) at java.util.StringTokenizer.<init>(StringTokenizer.java) at java.util.StringTokenizer.<init>(StringTokenizer.java) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage$NLSInputDialo g.getTokens(ExternalizeWizardPage.java:395) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage$NLSInputDialo g.dialogFieldChanged(ExternalizeWizardPage.java:388) at org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField.dialogFieldChanged (DialogField.java:70) at org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField.setText (StringDialogField.java:162) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage$NLSInputDialo g.<init>(ExternalizeWizardPage.java:347) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage.openEditButto n(ExternalizeWizardPage.java:953) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage.handleButtonP ressed(ExternalizeWizardPage.java:905) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage$10.widgetSele cted(ExternalizeWizardPage.java:875) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java) at org.eclipse.jface.window.Window.runEventLoop(Window.java) at org.eclipse.jface.window.Window.open(Window.java:648) at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation.run (RefactoringWizardOpenOperation.java:121) at org.eclipse.jdt.internal.ui.refactoring.actions.RefactoringStarter.activate (RefactoringStarter.java:40) at org.eclipse.jdt.ui.actions.ExternalizeStringsAction.openExternalizeStringsWizar d(ExternalizeStringsAction.java:157) at org.eclipse.jdt.ui.actions.ExternalizeStringsAction$1.run (ExternalizeStringsAction.java:126) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java) at org.eclipse.jdt.ui.actions.ExternalizeStringsAction.run (ExternalizeStringsAction.java:123) at org.eclipse.jdt.ui.actions.ExternalizeStringsAction.run (ExternalizeStringsAction.java:105) at org.eclipse.jdt.ui.actions.SelectionDispatchAction.dispatchRun (SelectionDispatchAction.java:216) at org.eclipse.jdt.ui.actions.SelectionDispatchAction.run (SelectionDispatchAction.java:188) at org.eclipse.jface.action.Action.runWithEvent(Action.java:881) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:899) at org.eclipse.jface.action.ActionContributionItem.access$2 (ActionContributionItem.java:850) at org.eclipse.jface.action.ActionContributionItem$7.handleEvent (ActionContributionItem.java:769) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1363) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1334) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench (Workbench.java:253) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:141) at org.eclipse.ui.internal.ide.IDEApplication.run (IDEApplication.java:97) at org.eclipse.core.internal.runtime.PlatformActivator$1.run (PlatformActivator.java:299) at org.eclipse.core.runtime.adaptor.EclipseStarter.run (EclipseStarter.java:256) at org.eclipse.core.runtime.adaptor.EclipseStarter.run (EclipseStarter.java:127) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:84) at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:59) at java.lang.reflect.Method.invoke(Method.java:390) at org.eclipse.core.launcher.Main.basicRun(Main.java:184) at org.eclipse.core.launcher.Main.run(Main.java:637) at org.eclipse.core.launcher.Main.main(Main.java:621)

Files changed in fix:
org.eclipse.jdt.ui/ui refactoring/org/eclipse/jdt/internal/ui/refactoring/nls/ExternalizeWizardPage.java