Project: JDT
Bug 60799 NPE trying to externalize strings [refactoring] [nls]
Reported: 2004-05-03 14:39:47 | Status: resolved fixed

I got the following NPE when I tried to externalize strings in N20040430 java.lang.NullPointerException at org.eclipse.jdt.internal.corext.refactoring.nls.NLSRefactoring.getPropertyFileP ath(NLSRefactoring.java:248) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage.updateAccesso rFieldLabels(ExternalizeWizardPage.java:525) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage.createAccesso rInfoComposite(ExternalizeWizardPage.java:518) at org.eclipse.jdt.internal.ui.refactoring.nls.ExternalizeWizardPage.createControl (ExternalizeWizardPage.java:453) at org.eclipse.jface.wizard.Wizard.createPageControls(Wizard.java:171) at org.eclipse.jface.wizard.WizardDialog.createPageControls (WizardDialog.java:539) at org.eclipse.jface.wizard.WizardDialog.createContents (WizardDialog.java:449) at org.eclipse.jface.window.Window.create(Window.java:348) at org.eclipse.jface.dialogs.Dialog.create(Dialog.java:935) at org.eclipse.jface.window.Window.open(Window.java:637) at org.eclipse.ltk.ui.refactoring.RefactoringWizardOpenOperation.run (RefactoringWizardOpenOperation.java:114) at org.eclipse.jdt.internal.ui.refactoring.actions.RefactoringStarter.activate (RefactoringStarter.java:40) at org.eclipse.jdt.ui.actions.ExternalizeStringsAction.openExternalizeStringsWizar d(ExternalizeStringsAction.java:151) at org.eclipse.jdt.ui.actions.ExternalizeStringsAction.run (ExternalizeStringsAction.java:122) at org.eclipse.jdt.ui.actions.ExternalizeStringsAction.run (ExternalizeStringsAction.java:112) at org.eclipse.jdt.ui.actions.SelectionDispatchAction.dispatchRun (SelectionDispatchAction.java:212) 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:612) at org.eclipse.jface.action.ActionContributionItem.access$2 (ActionContributionItem.java:564) at org.eclipse.jface.action.ActionContributionItem$6.handleEvent (ActionContributionItem.java:483) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:796) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:2592) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2270) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1353) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1324) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench (Workbench.java:240) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:140) at org.eclipse.ui.internal.ide.IDEApplication.run (IDEApplication.java:90) at org.eclipse.core.internal.runtime.PlatformActivator$1.run (PlatformActivator.java:283) at org.eclipse.core.runtime.adaptor.EclipseStarter.run (EclipseStarter.java:242) at org.eclipse.core.runtime.adaptor.EclipseStarter.run (EclipseStarter.java:119) 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:324) at org.eclipse.core.launcher.Main.basicRun(Main.java:269) at org.eclipse.core.launcher.Main.run(Main.java:700) at org.eclipse.core.launcher.Main.main(Main.java:684)

Files changed in fix:
org.eclipse.jdt.ui.tests.refactoring/test cases/org/eclipse/jdt/ui/tests/nls/NLSHintTest.java org.eclipse.jdt.ui.tests.refactoring/test cases/org/eclipse/jdt/ui/tests/nls/NlsRefactoringCheckFinalConditionsTest.java org.eclipse.jdt.ui.tests.refactoring/test cases/org/eclipse/jdt/ui/tests/nls/NlsRefactoringCreateChangeTest.java org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/nls/NLSHint.java org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/nls/NLSInfo.java org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/nls/NLSRefactoring.java org.eclipse.jdt.ui/ui refactoring/org/eclipse/jdt/internal/ui/refactoring/nls/ExternalizeWizardPage.java org.eclipse.jdt.ui/ui refactoring/org/eclipse/jdt/internal/ui/refactoring/nls/NLSAccessorConfigurationDialog.java org.eclipse.jdt.ui/ui refactoring/org/eclipse/jdt/internal/ui/refactoring/nls/PackageFragmentSelection.java org.eclipse.jdt.ui/ui refactoring/org/eclipse/jdt/internal/ui/refactoring/nls/PackageSelectionStringButtonAdapter.java org.eclipse.jdt.ui/ui refactoring/org/eclipse/jdt/internal/ui/refactoring/nls/SourceFirstPackageSelectionDialogField.java