issue_id
int64
2.04k
425k
title
stringlengths
9
251
body
stringlengths
4
32.8k
status
stringclasses
6 values
after_fix_sha
stringlengths
7
7
project_name
stringclasses
6 values
repo_url
stringclasses
6 values
repo_name
stringclasses
6 values
language
stringclasses
1 value
issue_url
null
before_fix_sha
null
pull_url
null
commit_datetime
timestamp[us, tz=UTC]
report_datetime
timestamp[us, tz=UTC]
updated_file
stringlengths
23
187
chunk_content
stringlengths
1
22k
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
public boolean isEnclosingTypeSelected() { return fEnclosingTypeSelection.isSelected(); } /** * Sets the enclosing type selection checkbox. * @param canBeModified Selects if the enclosing type selection can be changed by the user */ public void setEnclosingTypeSelection(boolean isSelected, boolean canBeModified) { fEnclosingTypeSelection.setSelection(isSelected); fEnclosingTypeSelection.setEnabled(canBeModified); updateEnableState(); } /** * Gets the type name. */ public String getTypeName() { return fTypeNameDialogField.getText(); } /** * Sets the type name. * @param canBeModified Selects if the type name can be changed by the user */ public void setTypeName(String name, boolean canBeModified) { fTypeNameDialogField.setText(name); fTypeNameDialogField.setEnabled(canBeModified); } /** * Gets the selected modifiers.
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
* @see Flags */ public int getModifiers() { int mdf= 0; if (fAccMdfButtons.isSelected(PUBLIC_INDEX)) { mdf+= IConstants.AccPublic; } else if (fAccMdfButtons.isSelected(PRIVATE_INDEX)) { mdf+= IConstants.AccPrivate; } else if (fAccMdfButtons.isSelected(PROTECTED_INDEX)) { mdf+= IConstants.AccProtected; } if (fOtherMdfButtons.isSelected(ABSTRACT_INDEX) && (fStaticMdfIndex != 0)) { mdf+= IConstants.AccAbstract; } if (fOtherMdfButtons.isSelected(FINAL_INDEX)) { mdf+= IConstants.AccFinal; } if (fOtherMdfButtons.isSelected(fStaticMdfIndex)) { mdf+= IConstants.AccStatic; } return mdf; } /** * Sets the modifiers. * @param canBeModified Selects if the modifiers can be changed by the user * @see IConstants */ public void setModifiers(int modifiers, boolean canBeModified) { if (Flags.isPublic(modifiers)) { fAccMdfButtons.setSelection(PUBLIC_INDEX, true);
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
} else if (Flags.isPrivate(modifiers)) { fAccMdfButtons.setSelection(PRIVATE_INDEX, true); } else if (Flags.isProtected(modifiers)) { fAccMdfButtons.setSelection(PROTECTED_INDEX, true); } else { fAccMdfButtons.setSelection(DEFAULT_INDEX, true); } if (Flags.isAbstract(modifiers)) { fOtherMdfButtons.setSelection(ABSTRACT_INDEX, true); } if (Flags.isFinal(modifiers)) { fOtherMdfButtons.setSelection(FINAL_INDEX, true); } if (Flags.isStatic(modifiers)) { fOtherMdfButtons.setSelection(fStaticMdfIndex, true); } fAccMdfButtons.setEnabled(canBeModified); fOtherMdfButtons.setEnabled(canBeModified); } /** * Gets the content of the super class text field. */ public String getSuperClass() { return fSuperClassDialogField.getText(); } /** * Sets the super class name. * @param canBeModified Selects if the super class can be changed by the user
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
*/ public void setSuperClass(String name, boolean canBeModified) { fSuperClassDialogField.setText(name); fSuperClassDialogField.setEnabled(canBeModified); } /** * Gets the currently chosen super interfaces. * @return returns a list of String */ public List getSuperInterfaces() { return fSuperInterfacesDialogField.getElements(); } /** * Sets the super interfaces. * @param canBeModified Selects if the modifiers can be changed by the user. * @param interfacesNames a list of String */ public void setSuperInterfaces(List interfacesNames, boolean canBeModified) { fSuperInterfacesDialogField.setElements(interfacesNames); fSuperInterfacesDialogField.setEnabled(canBeModified); } /** * Called when the package field has changed. * The method validates the package name and returns the status of the validation * This also updates the package fragment model. * Can be extended to add more validation
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
*/ protected IStatus packageChanged() { StatusInfo status= new StatusInfo(); fPackageDialogField.enableButton(getPackageFragmentRoot() != null); String packName= getPackageText(); if (packName.length() > 0) { IStatus val= JavaConventions.validatePackageName(packName); if (val.getSeverity() == IStatus.ERROR) { status.setError(NewWizardMessages.getFormattedString("NewTypeWizardPage.error.InvalidPackageName", val.getMessage())); return status; } else if (val.getSeverity() == IStatus.WARNING) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.DiscouragedPackageName", val.getMessage())); } } IPackageFragmentRoot root= getPackageFragmentRoot(); if (root != null) { IPackageFragment pack= root.getPackageFragment(packName); try { IPath rootPath= root.getPath(); IPath outputPath= root.getJavaProject().getOutputLocation(); if (rootPath.isPrefixOf(outputPath) && !rootPath.equals(outputPath)) { IPath packagePath= pack.getUnderlyingResource().getFullPath(); if (outputPath.isPrefixOf(packagePath)) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.ClashOutputLocation")); return status;
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
} } } catch (JavaModelException e) { JavaPlugin.log(e); } fCurrPackage= pack; } else { status.setError(""); } return status; } /* * Updates the 'default' label next to the package field. */ private void updatePackageStatusLabel() { String packName= getPackageText(); if (packName.length() == 0) { fPackageDialogField.setStatus(NewWizardMessages.getString("NewTypeWizardPage.default")); } else { fPackageDialogField.setStatus(""); } } /* * Updates the enable state of buttons related to the enclosing type selection checkbox. */ private void updateEnableState() {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
boolean enclosing= isEnclosingTypeSelected(); fPackageDialogField.setEnabled(fCanModifyPackage && !enclosing); fEnclosingTypeDialogField.setEnabled(fCanModifyEnclosingType && enclosing); } /** * Called when the enclosing type name has changed. * The method validates the enclosing type and returns the status of the validation * This also updates the enclosing type model. * Can be extended to add more validation */ protected IStatus enclosingTypeChanged() { StatusInfo status= new StatusInfo(); fCurrEnclosingType= null; IPackageFragmentRoot root= getPackageFragmentRoot(); fEnclosingTypeDialogField.enableButton(root != null); if (root == null) { status.setError(""); return status; } String enclName= getEnclosingTypeText(); if (enclName.length() == 0) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.EnclosingTypeEnterName")); return status; } try { IType type= JavaModelUtil.findType(root.getJavaProject(), enclName); if (type == null) {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.EnclosingTypeNotExists")); return status; } if (type.getCompilationUnit() == null) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.EnclosingNotInCU")); return status; } fCurrEnclosingType= type; IPackageFragmentRoot enclosingRoot= JavaModelUtil.getPackageFragmentRoot(type); if (!enclosingRoot.equals(root)) { status.setWarning(NewWizardMessages.getString("NewTypeWizardPage.warning.EnclosingNotInSourceFolder")); } return status; } catch (JavaModelException e) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.EnclosingTypeNotExists")); JavaPlugin.log(e); return status; } } /** * Called when the type name has changed. * The method validates the type name and returns the status of the validation. * Can be extended to add more validation */ protected IStatus typeNameChanged() { StatusInfo status= new StatusInfo(); String typeName= getTypeName(); if (typeName.length() == 0) {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.EnterTypeName")); return status; } if (typeName.indexOf('.') != -1) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.QualifiedName")); return status; } IStatus val= JavaConventions.validateJavaTypeName(typeName); if (val.getSeverity() == IStatus.ERROR) { status.setError(NewWizardMessages.getFormattedString("NewTypeWizardPage.error.InvalidTypeName", val.getMessage())); return status; } else if (val.getSeverity() == IStatus.WARNING) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.TypeNameDiscouraged", val.getMessage())); } if (!isEnclosingTypeSelected()) { IPackageFragment pack= getPackageFragment(); if (pack != null) { ICompilationUnit cu= pack.getCompilationUnit(typeName + ".java"); if (cu.exists()) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.TypeNameExists")); return status; } } } else { IType type= getEnclosingType(); if (type != null) { IType member= type.getType(typeName); if (member.exists()) {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.TypeNameExists")); return status; } } } return status; } /** * Called when the superclass name has changed. * The method validates the superclass name and returns the status of the validation. * Can be extended to add more validation */ protected IStatus superClassChanged() { StatusInfo status= new StatusInfo(); IPackageFragmentRoot root= getPackageFragmentRoot(); fSuperClassDialogField.enableButton(root != null); fSuperClass= null; String sclassName= getSuperClass(); if (sclassName.length() == 0) { return status; } IStatus val= JavaConventions.validateJavaTypeName(sclassName); if (val.getSeverity() == IStatus.ERROR) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.InvalidSuperClassName")); return status; }
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
if (root != null) { try { IType type= resolveSuperTypeName(root.getJavaProject(), sclassName); if (type == null) { status.setWarning(NewWizardMessages.getString("NewTypeWizardPage.warning.SuperClassNotExists")); return status; } else { if (type.isInterface()) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.SuperClassIsNotClass", sclassName)); return status; } int flags= type.getFlags(); if (Flags.isFinal(flags)) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.SuperClassIsFinal", sclassName)); return status; } else if (!JavaModelUtil.isVisible(type, getPackageFragment())) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.SuperClassIsNotVisible", sclassName)); return status; } } fSuperClass= type; } catch (JavaModelException e) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.InvalidSuperClassName")); JavaPlugin.log(e); } } else { status.setError(""); } return status;
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
} private IType resolveSuperTypeName(IJavaProject jproject, String sclassName) throws JavaModelException { IType type= null; if (isEnclosingTypeSelected()) { IType enclosingType= getEnclosingType(); if (enclosingType != null) { String[][] res= enclosingType.resolveType(sclassName); if (res != null && res.length > 0) { type= JavaModelUtil.findType(jproject, res[0][0], res[0][1]); } } } else { IPackageFragment currPack= getPackageFragment(); if (type == null && currPack != null) { String packName= currPack.getElementName(); if (!currPack.isDefaultPackage()) { type= JavaModelUtil.findType(jproject, packName, sclassName); } if (type == null && !"java.lang".equals(packName)) { type= JavaModelUtil.findType(jproject, "java.lang", sclassName); } } if (type == null) { type= JavaModelUtil.findType(jproject, sclassName); }
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
} return type; } /** * Called when the list of super interface has changed. * The method validates the superinterfaces and returns the status of the validation. * Can be extended to add more validation. */ protected IStatus superInterfacesChanged() { StatusInfo status= new StatusInfo(); IPackageFragmentRoot root= getPackageFragmentRoot(); fSuperInterfacesDialogField.enableButton(0, root != null); if (root != null) { List elements= fSuperInterfacesDialogField.getElements(); int nElements= elements.size(); for (int i= 0; i < nElements; i++) { String intfname= (String)elements.get(i); try { IType type= JavaModelUtil.findType(root.getJavaProject(), intfname); if (type == null) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.InterfaceNotExists", intfname)); return status; } else { if (type.isClass()) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.InterfaceIsNotInterface", intfname)); return status; }
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
if (!JavaModelUtil.isVisible(type, getPackageFragment())) { status.setWarning(NewWizardMessages.getFormattedString("NewTypeWizardPage.warning.InterfaceIsNotVisible", intfname)); return status; } } } catch (JavaModelException e) { JavaPlugin.log(e); } } } return status; } /** * Called when the modifiers have changed. * The method validates the modifiers and returns the status of the validation. * Can be extended to add more validation. */ protected IStatus modifiersChanged() { StatusInfo status= new StatusInfo(); int modifiers= getModifiers(); if (Flags.isFinal(modifiers) && Flags.isAbstract(modifiers)) { status.setError(NewWizardMessages.getString("NewTypeWizardPage.error.ModifiersFinalAndAbstract")); } return status; }
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
private IPackageFragment choosePackage() { IPackageFragmentRoot froot= getPackageFragmentRoot(); IJavaElement[] packages= null; try { if (froot != null) { packages= froot.getChildren(); } } catch (JavaModelException e) { JavaPlugin.log(e); } if (packages == null) { packages= new IJavaElement[0]; } ElementListSelectionDialog dialog= new ElementListSelectionDialog(getShell(), new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_DEFAULT)); dialog.setIgnoreCase(false); dialog.setTitle(NewWizardMessages.getString("NewTypeWizardPage.ChoosePackageDialog.title")); dialog.setMessage(NewWizardMessages.getString("NewTypeWizardPage.ChoosePackageDialog.description")); dialog.setEmptyListMessage(NewWizardMessages.getString("NewTypeWizardPage.ChoosePackageDialog.empty")); dialog.setElements(packages); if (fCurrPackage != null) { dialog.setInitialSelections(new Object[] { fCurrPackage }); } if (dialog.open() == dialog.OK) { return (IPackageFragment) dialog.getFirstResult(); } return null; } private IType chooseEnclosingType() {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
IPackageFragmentRoot root= getPackageFragmentRoot(); if (root == null) { return null; } IJavaSearchScope scope= SearchEngine.createJavaSearchScope(new IJavaElement[] { root }); TypeSelectionDialog dialog= new TypeSelectionDialog(getShell(), getWizard().getContainer(), IJavaSearchConstants.TYPE, scope); dialog.setTitle(NewWizardMessages.getString("NewTypeWizardPage.ChooseEnclosingTypeDialog.title")); dialog.setMessage(NewWizardMessages.getString("NewTypeWizardPage.ChooseEnclosingTypeDialog.description")); if (fCurrEnclosingType != null) { dialog.setInitialSelections(new Object[] { fCurrEnclosingType }); dialog.setFilter(fCurrEnclosingType.getElementName().substring(0, 1)); } if (dialog.open() == dialog.OK) { return (IType) dialog.getFirstResult(); } return null; } private IType chooseSuperType() { IPackageFragmentRoot root= getPackageFragmentRoot(); if (root == null) { return null; } IJavaElement[] elements= new IJavaElement[] { root.getJavaProject() }; IJavaSearchScope scope= SearchEngine.createJavaSearchScope(elements); TypeSelectionDialog dialog= new TypeSelectionDialog(getShell(), getWizard().getContainer(), IJavaSearchConstants.CLASS, scope); dialog.setTitle(NewWizardMessages.getString("NewTypeWizardPage.SuperClassDialog.title"));
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
dialog.setMessage(NewWizardMessages.getString("NewTypeWizardPage.SuperClassDialog.message")); if (fSuperClass != null) { dialog.setFilter(fSuperClass.getElementName()); } if (dialog.open() == dialog.OK) { return (IType) dialog.getFirstResult(); } return null; } private void chooseSuperInterfaces() { IPackageFragmentRoot root= getPackageFragmentRoot(); if (root == null) { return; } IJavaProject project= root.getJavaProject(); SuperInterfaceSelectionDialog dialog= new SuperInterfaceSelectionDialog(getShell(), getWizard().getContainer(), fSuperInterfacesDialogField, project); dialog.setTitle(fIsClass ? NewWizardMessages.getString("NewTypeWizardPage.InterfacesDialog.class.title") : NewWizardMessages.getString("NewTypeWizardPage.InterfacesDialog.interface.title")); dialog.setMessage(NewWizardMessages.getString("NewTypeWizardPage.InterfacesDialog.message")); dialog.open(); return; } /** * Creates a type using the current field values. */ public void createType(IProgressMonitor monitor) throws CoreException, InterruptedException {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
monitor.beginTask(NewWizardMessages.getString("NewTypeWizardPage.operationdesc"), 10); IPackageFragmentRoot root= getPackageFragmentRoot(); IPackageFragment pack= getPackageFragment(); if (pack == null) { pack= root.getPackageFragment(""); } if (!pack.exists()) { String packName= pack.getElementName(); pack= root.createPackageFragment(packName, true, null); } monitor.worked(1); String clName= getTypeName(); boolean isInnerClass= isEnclosingTypeSelected(); IType createdType; ImportsStructure imports; int indent= 0; String[] prefOrder= ImportOrganizePreferencePage.getImportOrderPreference(); int threshold= ImportOrganizePreferencePage.getImportNumberThreshold(); String lineDelimiter= null; if (!isInnerClass) { lineDelimiter= System.getProperty("line.separator", "\n"); String packStatement= pack.isDefaultPackage() ? "" : "package " + pack.getElementName() + ";" + lineDelimiter + lineDelimiter;
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
ICompilationUnit parentCU= pack.createCompilationUnit(clName + ".java", packStatement, false, new SubProgressMonitor(monitor, 2)); imports= new ImportsStructure(parentCU, prefOrder, threshold, false); String content= constructTypeStub(imports, lineDelimiter, parentCU); createdType= parentCU.createType(content, null, false, new SubProgressMonitor(monitor, 3)); } else { IType enclosingType= getEnclosingType(); IType workingCopy= (IType) EditorUtility.getWorkingCopy(enclosingType); if (workingCopy != null) { enclosingType= workingCopy; } ICompilationUnit parentCU= enclosingType.getCompilationUnit(); imports= new ImportsStructure(parentCU, prefOrder, threshold, true); lineDelimiter= StubUtility.getLineDelimiterUsed(enclosingType); String content= constructTypeStub(imports, lineDelimiter, parentCU); IJavaElement[] elems= enclosingType.getChildren(); IJavaElement sibling= elems.length > 0 ? elems[0] : null; createdType= enclosingType.createType(content, sibling, false, new SubProgressMonitor(monitor, 1)); indent= StubUtility.getIndentUsed(enclosingType) + 1; } imports.create(!isInnerClass, new SubProgressMonitor(monitor, 1));
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
createTypeMembers(createdType, imports, new SubProgressMonitor(monitor, 1)); imports.create(!isInnerClass, new SubProgressMonitor(monitor, 1)); ICompilationUnit cu= createdType.getCompilationUnit(); ISourceRange range; if (isInnerClass) { synchronized(cu) { cu.reconcile(null); } range= createdType.getSourceRange(); } else { range= cu.getSourceRange(); } IBuffer buf= cu.getBuffer(); String originalContent= buf.getText(range.getOffset(), range.getLength()); String formattedContent= StubUtility.codeFormat(originalContent, indent, lineDelimiter); buf.replace(range.getOffset(), range.getLength(), formattedContent); if (!isInnerClass) { String fileComment= getFileComment(cu); if (fileComment != null && fileComment.length() > 0) { buf.replace(0, 0, fileComment + lineDelimiter); } buf.save(new SubProgressMonitor(monitor, 1), false); } else { monitor.worked(1); } fCreatedType= createdType; monitor.done();
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
} /** * Returns the created type. Only valid after createType has been invoked */ public IType getCreatedType() { return fCreatedType; } private void writeSuperClass(StringBuffer buf, IImportsStructure imports) { String typename= getSuperClass(); if (fIsClass && typename.length() > 0 && !"java.lang.Object".equals(typename)) { buf.append(" extends "); buf.append(Signature.getSimpleName(typename)); if (fSuperClass != null) { imports.addImport(JavaModelUtil.getFullyQualifiedName(fSuperClass)); } else { imports.addImport(typename); } } } private void writeSuperInterfaces(StringBuffer buf, IImportsStructure imports) { List interfaces= getSuperInterfaces(); int last= interfaces.size() - 1; if (last >= 0) { if (fIsClass) { buf.append(" implements "); } else {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
buf.append(" extends "); } for (int i= 0; i <= last; i++) { String typename= (String) interfaces.get(i); imports.addImport(typename); buf.append(Signature.getSimpleName(typename)); if (i < last) { buf.append(','); } } } } /* * Called from createType to construct the source for this type */ private String constructTypeStub(IImportsStructure imports, String lineDelimiter, ICompilationUnit parentCU) { StringBuffer buf= new StringBuffer(); String typeComment= getTypeComment(parentCU); if (typeComment != null && typeComment.length() > 0) { buf.append(typeComment); buf.append(lineDelimiter); } int modifiers= getModifiers(); buf.append(Flags.toString(modifiers)); if (modifiers != 0) { buf.append(' '); } buf.append(fIsClass ? "class " : "interface "); buf.append(getTypeName());
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
writeSuperClass(buf, imports); writeSuperInterfaces(buf, imports); buf.append('{'); buf.append(lineDelimiter); buf.append(lineDelimiter); buf.append('}'); buf.append(lineDelimiter); return buf.toString(); } /** * Called from createType to allow adding methods, fielse, inner types ect for the newly created type. * Implementors can use the create methods on the new type. * Formatting will be applied to the content by the createType * @param newType The new type to add members to * @param imports To add the needed imports to. * @param monitor Progress monitor */ protected void createTypeMembers(IType newType, IImportsStructure imports, IProgressMonitor monitor) throws CoreException { } /** * Called from createType to get a file comment. By default the content of template * 'filecomment' is taken. * Returns source or null, if no file comment should be added */ protected String getFileComment(ICompilationUnit parentCU) {
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
if (CodeGenerationPreferencePage.doFileComments()) { return getTemplate("filecomment", parentCU); } return null; } /** * Called from createType to get a type comment. * Returns source or null, if no type comment should be added */ protected String getTypeComment(ICompilationUnit parentCU) { if (CodeGenerationPreferencePage.doCreateComments()) { return getTemplate("typecomment", parentCU); } return null; } /** * Gets the template of the given name, evaluated in the context of a CU. */ protected String getTemplate(String name, ICompilationUnit parentCU) { Template[] templates= Templates.getInstance().getTemplates(); try { for (int i= 0; i < templates.length; i++) { if (name.equals(templates[i].getName())) { return JavaContext.evaluateTemplate(templates[i], parentCU); } } } catch (CoreException e) { JavaPlugin.log(e);
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
} return null; } /** * Creates the bodies of all unimplemented methods or/and all constructors and adds them to the type * Can be used by implementors of NewTypeWizardPage to add method stub checkboxes. */ protected IMethod[] createInheritedMethods(IType type, boolean doConstructors, boolean doUnimplementedMethods, IImportsStructure imports, IProgressMonitor monitor) throws CoreException { List newMethods= new ArrayList(); ITypeHierarchy hierarchy= type.newSupertypeHierarchy(monitor); CodeGenerationSettings settings= JavaPreferencesSettings.getCodeGenerationSettings(); if (doConstructors) { IType superclass= hierarchy.getSuperclass(type); if (superclass != null) { String[] constructors= StubUtility.evalConstructors(type, superclass, settings, imports); if (constructors != null) { for (int i= 0; i < constructors.length; i++) { newMethods.add(constructors[i]); } } } } if (doUnimplementedMethods) { String[] unimplemented= StubUtility.evalUnimplementedMethods(type, hierarchy, false, settings, null, imports); if (unimplemented != null) { for (int i= 0; i < unimplemented.length; i++) { newMethods.add(unimplemented[i]); }
12,108
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
resolved fixed
24b70db
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T16:27:53Z
2002-03-22T15:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
} } IMethod[] createdMethods= new IMethod[newMethods.size()]; for (int i= 0; i < newMethods.size(); i++) { createdMethods[i]= type.createMethod((String) newMethods.get(i), null, false, null); } return createdMethods; } /** * Returns a runnable that creates a type using the current settings. */ public IRunnableWithProgress getRunnable() { return new IRunnableWithProgress() { public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException { try { if (monitor == null) { monitor= new NullProgressMonitor(); } createType(monitor); } catch (CoreException e) { throw new InvocationTargetException(e); } } }; } }
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
/* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ package org.eclipse.jdt.internal.ui.preferences; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; import java.util.Hashtable; import org.eclipse.swt.SWT; import org.eclipse.swt.events.ModifyEvent; import org.eclipse.swt.events.ModifyListener; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control;
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.TabFolder; import org.eclipse.swt.widgets.TabItem; import org.eclipse.swt.widgets.Text; import org.eclipse.core.runtime.IStatus; import org.eclipse.jface.preference.IPreferenceStore; import org.eclipse.jface.preference.PreferencePage; import org.eclipse.jface.resource.JFaceResources; import org.eclipse.jface.text.Document; import org.eclipse.jface.text.IDocument; import org.eclipse.jface.text.source.SourceViewer; import org.eclipse.ui.IWorkbench; import org.eclipse.ui.IWorkbenchPreferencePage; import org.eclipse.ui.help.DialogPageContextComputer; import org.eclipse.ui.help.WorkbenchHelp; import org.eclipse.jdt.core.JavaCore; import org.eclipse.jdt.ui.text.JavaSourceViewerConfiguration; import org.eclipse.jdt.ui.text.JavaTextTools; import org.eclipse.jdt.internal.formatter.CodeFormatter; import org.eclipse.jdt.internal.ui.IJavaHelpContextIds; import org.eclipse.jdt.internal.ui.JavaPlugin; import org.eclipse.jdt.internal.ui.JavaPluginImages; import org.eclipse.jdt.internal.ui.JavaUIMessages; import org.eclipse.jdt.internal.ui.dialogs.StatusInfo; import org.eclipse.jdt.internal.ui.dialogs.StatusUtil; import org.eclipse.jdt.internal.ui.util.TabFolderLayout; /* * The page for setting code formatter options */ public class CodeFormatterPreferencePage extends PreferencePage implements IWorkbenchPreferencePage {
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
private static final String PREF_NEWLINE_OPENING_BRACES= "org.eclipse.jdt.core.formatter.newline.openingBrace"; private static final String PREF_NEWLINE_CONTROL_STATEMENT= "org.eclipse.jdt.core.formatter.newline.controlStatement"; private static final String PREF_NEWLINE_CLEAR_ALL= "org.eclipse.jdt.core.formatter.newline.clearAll"; private static final String PREF_NEWLINE_ELSE_IF= "org.eclipse.jdt.core.formatter.newline.elseIf"; private static final String PREF_NEWLINE_EMPTY_BLOCK= "org.eclipse.jdt.core.formatter.newline.emptyBlock"; private static final String PREF_LINE_SPLIT= "org.eclipse.jdt.core.formatter.lineSplit"; private static final String PREF_STYLE_COMPACT_ASSIGNEMENT= "org.eclipse.jdt.core.formatter.style.assignment"; private static final String PREF_TAB_CHAR= "org.eclipse.jdt.core.formatter.tabulation.char"; private static final String PREF_TAB_SIZE= "org.eclipse.jdt.core.formatter.tabulation.size"; private static final String INSERT= "insert"; private static final String DO_NOT_INSERT= "do not insert"; private static final String COMPACT= "compact"; private static final String NORMAL= "normal"; private static final String TAB= "tab"; private static final String SPACE= "space"; private static final String CLEAR_ALL= "clear all"; private static final String PRESERVE_ONE= "preserve one"; private static String[] getAllKeys() { return new String[] { PREF_NEWLINE_OPENING_BRACES, PREF_NEWLINE_CONTROL_STATEMENT, PREF_NEWLINE_CLEAR_ALL, PREF_NEWLINE_ELSE_IF, PREF_NEWLINE_EMPTY_BLOCK, PREF_LINE_SPLIT,
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
PREF_STYLE_COMPACT_ASSIGNEMENT, PREF_TAB_CHAR, PREF_TAB_SIZE }; } /** * Gets the currently configured tab size */ public static int getTabSize() { String string= (String) JavaCore.getOptions().get(PREF_TAB_SIZE); return getIntValue(string, 4); } /** * Gets the current compating assignement configuration */ public static boolean isCompactingAssignment() { return COMPACT.equals(JavaCore.getOptions().get(PREF_STYLE_COMPACT_ASSIGNEMENT)); } /** * Gets the current compating assignement configuration */ public static boolean useSpaces() { return SPACE.equals(JavaCore.getOptions().get(PREF_TAB_CHAR)); } private static int getIntValue(String string, int dflt) { try { return Integer.parseInt(string);
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
} catch (NumberFormatException e) { } return dflt; } /** * Initializes the current options (read from preference store) */ public static void initDefaults(IPreferenceStore store) { Hashtable hashtable= JavaCore.getDefaultOptions(); Hashtable currOptions= JavaCore.getOptions(); String[] allKeys= getAllKeys(); for (int i= 0; i < allKeys.length; i++) { String key= allKeys[i]; String defValue= (String) hashtable.get(key); if (defValue != null) { store.setDefault(key, defValue); } else { JavaPlugin.logErrorMessage("CodeFormatterPreferencePage: value is null: " + key); } String val= store.getString(key); if (val != null) { currOptions.put(key, val); } } JavaCore.setOptions(currOptions); } private static class ControlData {
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
private String fKey; private String[] fValues; public ControlData(String key, String[] values) { fKey= key; fValues= values; } public String getKey() { return fKey; } public String getValue(boolean selection) { int index= selection ? 0 : 1; return fValues[index]; } public String getValue(int index) { return fValues[index]; } public int getSelection(String value) {
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
for (int i= 0; i < fValues.length; i++) { if (value.equals(fValues[i])) { return i; } } throw new IllegalArgumentException(); } } private Hashtable fWorkingValues; private ArrayList fCheckBoxes; private ArrayList fTextBoxes; private SelectionListener fButtonSelectionListener; private ModifyListener fTextModifyListener; private String fPreviewText; private IDocument fPreviewDocument; private Text fTabSizeTextBox; private SourceViewer fSourceViewer; public CodeFormatterPreferencePage() { setPreferenceStore(JavaPlugin.getDefault().getPreferenceStore()); setDescription(JavaUIMessages.getString("CodeFormatterPreferencePage.description")); fWorkingValues= JavaCore.getOptions(); fCheckBoxes= new ArrayList(); fTextBoxes= new ArrayList();
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
fButtonSelectionListener= new SelectionListener() { public void widgetDefaultSelected(SelectionEvent e) {} public void widgetSelected(SelectionEvent e) { if (!e.widget.isDisposed()) { controlChanged((Button) e.widget); } } }; fTextModifyListener= new ModifyListener() { public void modifyText(ModifyEvent e) { if (!e.widget.isDisposed()) { textChanged((Text) e.widget); } } }; fPreviewDocument= new Document(); fPreviewText= loadPreviewFile("CodeFormatterPreviewCode.txt"); } /* * @see IWorkbenchPreferencePage#init() */ public void init(IWorkbench workbench) { } /* * @see PreferencePage#createControl(Composite) */ public void createControl(Composite parent) { super.createControl(parent);
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
WorkbenchHelp.setHelp(getControl(), IJavaHelpContextIds.CODEFORMATTER_PREFERENCE_PAGE); } /* * @see PreferencePage#createContents(Composite) */ protected Control createContents(Composite parent) { GridLayout layout= new GridLayout(); layout.marginHeight= 0; layout.marginWidth= 0; Composite composite= new Composite(parent, SWT.NONE); composite.setLayout(layout); TabFolder folder= new TabFolder(composite, SWT.NONE); folder.setLayout(new TabFolderLayout()); folder.setLayoutData(new GridData(GridData.FILL_BOTH)); String[] insertNotInsert= new String[] { INSERT, DO_NOT_INSERT }; layout= new GridLayout(); layout.numColumns= 2; Composite newlineComposite= new Composite(folder, SWT.NULL); newlineComposite.setLayout(layout); String label= JavaUIMessages.getString("CodeFormatterPreferencePage.newline_opening_braces.label"); addCheckBox(newlineComposite, label, PREF_NEWLINE_OPENING_BRACES, insertNotInsert); label= JavaUIMessages.getString("CodeFormatterPreferencePage.newline_control_statement.label");
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
addCheckBox(newlineComposite, label, PREF_NEWLINE_CONTROL_STATEMENT, insertNotInsert); label= JavaUIMessages.getString("CodeFormatterPreferencePage.newline_clear_lines"); addCheckBox(newlineComposite, label, PREF_NEWLINE_CLEAR_ALL, new String[] { CLEAR_ALL, PRESERVE_ONE } ); label= JavaUIMessages.getString("CodeFormatterPreferencePage.newline_else_if.label"); addCheckBox(newlineComposite, label, PREF_NEWLINE_ELSE_IF, insertNotInsert); label= JavaUIMessages.getString("CodeFormatterPreferencePage.newline_empty_block.label"); addCheckBox(newlineComposite, label, PREF_NEWLINE_EMPTY_BLOCK, insertNotInsert); layout= new GridLayout(); layout.numColumns= 2; Composite lineSplittingComposite= new Composite(folder, SWT.NULL); lineSplittingComposite.setLayout(layout); label= JavaUIMessages.getString("CodeFormatterPreferencePage.split_line.label"); addTextField(lineSplittingComposite, label, PREF_LINE_SPLIT); layout= new GridLayout(); layout.numColumns= 2; Composite styleComposite= new Composite(folder, SWT.NULL); styleComposite.setLayout(layout); label= JavaUIMessages.getString("CodeFormatterPreferencePage.style_compact_assignement.label"); addCheckBox(styleComposite, label, PREF_STYLE_COMPACT_ASSIGNEMENT, new String[] { COMPACT, NORMAL } ); label= JavaUIMessages.getString("CodeFormatterPreferencePage.tab_char.label"); addCheckBox(styleComposite, label, PREF_TAB_CHAR, new String[] { TAB, SPACE } ); label= JavaUIMessages.getString("CodeFormatterPreferencePage.tab_size.label"); fTabSizeTextBox= addTextField(styleComposite, label, PREF_TAB_SIZE); TabItem item= new TabItem(folder, SWT.NONE); item.setText(JavaUIMessages.getString("CodeFormatterPreferencePage.tab.newline.tabtitle")); item.setImage(JavaPluginImages.get(JavaPluginImages.IMG_OBJS_IMPDECL));
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
item.setControl(newlineComposite); item= new TabItem(folder, SWT.NONE); item.setText(JavaUIMessages.getString("CodeFormatterPreferencePage.tab.linesplit.tabtitle")); item.setImage(JavaPluginImages.get(JavaPluginImages.IMG_OBJS_CFILE)); item.setControl(lineSplittingComposite); item= new TabItem(folder, SWT.NONE); item.setText(JavaUIMessages.getString("CodeFormatterPreferencePage.tab.style.tabtitle")); item.setImage(JavaPluginImages.get(JavaPluginImages.IMG_OBJS_SEARCH_REF)); item.setControl(styleComposite); fSourceViewer= createPreview(parent); updatePreview(); return composite; } private SourceViewer createPreview(Composite parent) { SourceViewer previewViewer= new SourceViewer(parent, null, SWT.V_SCROLL | SWT.H_SCROLL); JavaTextTools tools= JavaPlugin.getDefault().getJavaTextTools(); previewViewer.configure(new JavaSourceViewerConfiguration(tools, null)); previewViewer.getTextWidget().setFont(JFaceResources.getFontRegistry().get(JFaceResources.TEXT_FONT)); previewViewer.getTextWidget().setTabs(getIntValue((String) fWorkingValues.get(PREF_TAB_SIZE), 0)); previewViewer.setEditable(false); previewViewer.setDocument(fPreviewDocument); Control control= previewViewer.getControl(); GridData gdata= new GridData(GridData.FILL_BOTH); gdata.widthHint= convertWidthInCharsToPixels(80); gdata.heightHint= convertHeightInCharsToPixels(15);
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
control.setLayoutData(gdata); return previewViewer; } private Button addCheckBox(Composite parent, String label, String key, String[] values) { ControlData data= new ControlData(key, values); GridData gd= new GridData(GridData.FILL_HORIZONTAL); gd.horizontalSpan= 2; Button checkBox= new Button(parent, SWT.CHECK); checkBox.setText(label); checkBox.setData(data); checkBox.setLayoutData(gd); String currValue= (String)fWorkingValues.get(key); checkBox.setSelection(data.getSelection(currValue) == 0); checkBox.addSelectionListener(fButtonSelectionListener); fCheckBoxes.add(checkBox); return checkBox; } private Text addTextField(Composite parent, String label, String key) { Label labelControl= new Label(parent, SWT.NONE); labelControl.setText(label); labelControl.setLayoutData(new GridData()); Text textBox= new Text(parent, SWT.BORDER | SWT.SINGLE); textBox.setData(key);
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
textBox.setLayoutData(new GridData()); String currValue= (String)fWorkingValues.get(key); textBox.setText(String.valueOf(getIntValue(currValue, 1))); textBox.setTextLimit(3); textBox.addModifyListener(fTextModifyListener); GridData gd= new GridData(); gd.widthHint= convertWidthInCharsToPixels(5); textBox.setLayoutData(gd); fTextBoxes.add(textBox); return textBox; } private void controlChanged(Button button) { ControlData data= (ControlData) button.getData(); boolean selection= button.getSelection(); String newValue= data.getValue(selection); fWorkingValues.put(data.getKey(), newValue); updatePreview(); if (PREF_TAB_CHAR.equals(data.getKey())) { updateStatus(new StatusInfo()); if (selection) { fTabSizeTextBox.setText((String)fWorkingValues.get(PREF_TAB_SIZE)); } } } private void textChanged(Text textControl) { String key= (String) textControl.getData();
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
String number= textControl.getText(); IStatus status= validatePositiveNumber(number); if (!status.matches(IStatus.ERROR)) { fWorkingValues.put(key, number); } if (PREF_TAB_SIZE.equals(key)) { fSourceViewer.getTextWidget().setTabs(getIntValue(number, 0)); } updateStatus(status); updatePreview(); } /* * @see IPreferencePage#performOk() */ public boolean performOk() { String[] allKeys= getAllKeys(); Hashtable actualOptions= JavaCore.getOptions(); IPreferenceStore store= getPreferenceStore(); for (int i= 0; i < allKeys.length; i++) { String key= allKeys[i]; String val= (String) fWorkingValues.get(key); actualOptions.put(key, val); store.setValue(key, val); } JavaCore.setOptions(actualOptions); return super.performOk();
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
} /* * @see PreferencePage#performDefaults() */ protected void performDefaults() { fWorkingValues= JavaCore.getDefaultOptions(); updateControls(); super.performDefaults(); } private String loadPreviewFile(String filename) { String separator= System.getProperty("line.separator"); StringBuffer btxt= new StringBuffer(512); BufferedReader rin= null; try { rin= new BufferedReader(new InputStreamReader(getClass().getResourceAsStream(filename))); String line; while ((line= rin.readLine()) != null) { btxt.append(line); btxt.append(separator); } } catch (IOException io) { JavaPlugin.log(io); } finally { if (rin != null) { try { rin.close(); } catch (IOException e) {} } } return btxt.toString(); }
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
private void updatePreview() { fPreviewDocument.set(new CodeFormatter(fWorkingValues).format(fPreviewText)); } private void updateControls() { for (int i= fCheckBoxes.size() - 1; i >= 0; i--) { Button curr= (Button) fCheckBoxes.get(i); ControlData data= (ControlData) curr.getData(); String currValue= (String) fWorkingValues.get(data.getKey()); curr.setSelection(data.getSelection(currValue) == 0); } for (int i= fTextBoxes.size() - 1; i >= 0; i--) { Text curr= (Text) fTextBoxes.get(i); String key= (String) curr.getData(); String currValue= (String) fWorkingValues.get(key); curr.setText(currValue); } } private IStatus validatePositiveNumber(String number) { StatusInfo status= new StatusInfo(); if (number.length() == 0) { status.setError(JavaUIMessages.getString("CodeFormatterPreferencePage.empty_input")); } else { try { int value= Integer.parseInt(number); if (value < 0) { status.setError(JavaUIMessages.getFormattedString("CodeFormatterPreferencePage.invalid_input", number));
11,833
Bug 11833 NegativeArraySizeException in code formatter/style pref page
20020319 enter -1 as number of spaces representing a tab java.lang.NegativeArraySizeException at java.lang.StringBuffer.<init>(StringBuffer.java(Compiled Code)) at org.eclipse.swt.custom.StyledText.calculateTabWidth (StyledText.java:1386) at org.eclipse.swt.custom.StyledText.setTabs(StyledText.java:7293) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.textChanged (CodeFormatterPreferencePage.java:408) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage.access$1 (CodeFormatterPreferencePage.java:400) at org.eclipse.jdt.internal.ui.preferences.CodeFormatterPreferencePage$2.modifyText (CodeFormatterPreferencePage.java:218) at org.eclipse.swt.widgets.TypedListener.handleEvent (TypedListener.java:179) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Text.wmCommandChild(Text.java:1751) at org.eclipse.swt.widgets.Control.WM_COMMAND(Control.java:2786) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.CallWindowProcW(Native Method) at org.eclipse.swt.internal.win32.OS.CallWindowProc(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Text.callWindowProc(Text.java:85) at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled Code)) at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled Code)) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.jface.window.Window.runEventLoop(Window.java(Compiled Code)) at org.eclipse.jface.window.Window.open(Window.java:525) at org.eclipse.ui.internal.OpenPreferencesAction.run (OpenPreferencesAction.java:47) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection (ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent (ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0 (ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent (ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java (Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java (Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java (Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run (InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.Main.main(Main.java:396)
resolved fixed
255c5b9
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:26:01Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeFormatterPreferencePage.java
} } catch (NumberFormatException e) { status.setError(JavaUIMessages.getFormattedString("CodeFormatterPreferencePage.invalid_input", number)); } } return status; } private void updateStatus(IStatus status) { if (!status.matches(IStatus.ERROR)) { for (int i= 0; i < fTextBoxes.size(); i++) { Text curr= (Text) fTextBoxes.get(i); if (!(curr == fTabSizeTextBox && usesTabs())) { IStatus currStatus= validatePositiveNumber(curr.getText()); status= StatusUtil.getMoreSevere(currStatus, status); } } } setValid(!status.matches(IStatus.ERROR)); StatusUtil.applyToStatusLine(this, status); } private boolean usesTabs() { return TAB.equals(fWorkingValues.get(PREF_TAB_CHAR)); } }
11,826
Bug 11826 Build exclusion filter should be trimmed prior to storing
null
resolved fixed
574cdab
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:42:21Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/JavaBuilderPreferencePage.java
/* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ package org.eclipse.jdt.internal.ui.preferences; import java.lang.reflect.InvocationTargetException; import java.util.Hashtable; import java.util.StringTokenizer; import org.eclipse.core.resources.IResource; import org.eclipse.core.resources.IWorkspace; import org.eclipse.core.resources.IncrementalProjectBuilder; import org.eclipse.core.resources.ResourcesPlugin; import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IStatus; import org.eclipse.swt.SWT; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control; import org.eclipse.jface.dialogs.MessageDialog; import org.eclipse.jface.dialogs.ProgressMonitorDialog; import org.eclipse.jface.operation.IRunnableWithProgress; import org.eclipse.jface.preference.IPreferenceStore; import org.eclipse.jface.preference.PreferencePage; import org.eclipse.ui.IWorkbench; import org.eclipse.ui.IWorkbenchPreferencePage; import org.eclipse.jdt.core.JavaCore; import org.eclipse.jdt.internal.ui.JavaPlugin; import org.eclipse.jdt.internal.ui.JavaUIMessages; import org.eclipse.jdt.internal.ui.dialogs.StatusInfo;
11,826
Bug 11826 Build exclusion filter should be trimmed prior to storing
null
resolved fixed
574cdab
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:42:21Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/JavaBuilderPreferencePage.java
import org.eclipse.jdt.internal.ui.dialogs.StatusUtil; import org.eclipse.jdt.internal.ui.util.ExceptionHandler; import org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField; import org.eclipse.jdt.internal.ui.wizards.dialogfields.IDialogFieldListener; import org.eclipse.jdt.internal.ui.wizards.dialogfields.LayoutUtil; import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField; public class JavaBuilderPreferencePage extends PreferencePage implements IWorkbenchPreferencePage { private StringDialogField fResourceFilterField; private StatusInfo fResourceFilterStatus; private Hashtable fWorkingValues; private static final String PREF_RESOURCE_FILTER= "org.eclipse.jdt.core.builder.resourceCopyExclusionFilter"; private static String[] getAllKeys() { return new String[] { PREF_RESOURCE_FILTER }; } public JavaBuilderPreferencePage() { setPreferenceStore(JavaPlugin.getDefault().getPreferenceStore()); setDescription(JavaUIMessages.getString("JavaBuilderPreferencePage.description")); fWorkingValues= JavaCore.getOptions(); IDialogFieldListener listener= new IDialogFieldListener() { public void dialogFieldChanged(DialogField field) { doValidation(); } }; fResourceFilterField= new StringDialogField();
11,826
Bug 11826 Build exclusion filter should be trimmed prior to storing
null
resolved fixed
574cdab
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:42:21Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/JavaBuilderPreferencePage.java
fResourceFilterField.setDialogFieldListener(listener); fResourceFilterField.setLabelText(JavaUIMessages.getString("JavaBuilderPreferencePage.filter.label")); updateControls(); } /* * @see PreferencePage#createContents(Composite) */ protected Control createContents(Composite parent) { initializeDialogUnits(parent); GridLayout layout= new GridLayout(); layout.marginHeight= 0; layout.marginWidth= 0; layout.numColumns= 2; Composite composite= new Composite(parent, SWT.NONE); composite.setLayout(layout); DialogField resourceFilterLabel= new DialogField(); resourceFilterLabel.setLabelText(JavaUIMessages.getString("JavaBuilderPreferencePage.filter.description")); resourceFilterLabel.doFillIntoGrid(composite, 2); LayoutUtil.setWidthHint(resourceFilterLabel.getLabelControl(null), convertWidthInCharsToPixels(80)); fResourceFilterField.doFillIntoGrid(composite, 2); LayoutUtil.setHorizontalGrabbing(fResourceFilterField.getTextControl(null)); LayoutUtil.setWidthHint(fResourceFilterField.getTextControl(null), convertWidthInCharsToPixels(50)); return composite; } /** * Initializes the current options (read from preference store)
11,826
Bug 11826 Build exclusion filter should be trimmed prior to storing
null
resolved fixed
574cdab
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:42:21Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/JavaBuilderPreferencePage.java
*/ public static void initDefaults(IPreferenceStore store) { Hashtable hashtable= JavaCore.getDefaultOptions(); Hashtable currOptions= JavaCore.getOptions(); String[] allKeys= getAllKeys(); for (int i= 0; i < allKeys.length; i++) { String key= allKeys[i]; String defValue= (String) hashtable.get(key); if (defValue != null) { store.setDefault(key, defValue); } else { JavaPlugin.logErrorMessage("JavaBuilderPreferencePage: value is null: " + key); } String val= store.getString(key); if (val != null) { currOptions.put(key, val); } } JavaCore.setOptions(currOptions); } /* * @see IWorkbenchPreferencePage#init(IWorkbench) */ public void init(IWorkbench workbench) { } /* * @see IPreferencePage#performOk() */
11,826
Bug 11826 Build exclusion filter should be trimmed prior to storing
null
resolved fixed
574cdab
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:42:21Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/JavaBuilderPreferencePage.java
public boolean performOk() { String[] allKeys= getAllKeys(); Hashtable actualOptions= JavaCore.getOptions(); IPreferenceStore store= getPreferenceStore(); boolean hasChanges= false; for (int i= 0; i < allKeys.length; i++) { String key= allKeys[i]; String val= (String) fWorkingValues.get(key); String oldVal= (String) actualOptions.get(key); hasChanges= hasChanges | !val.equals(oldVal); actualOptions.put(key, val); store.setValue(key, val); } JavaCore.setOptions(actualOptions); if (hasChanges) { String title= JavaUIMessages.getString("JavaBuilderPreferencePage.needsbuild.title"); String message= JavaUIMessages.getString("JavaBuilderPreferencePage.needsbuild.message"); if (MessageDialog.openQuestion(getShell(), title, message)) { doFullBuild(); } } return super.performOk(); } private void doValidation() { fWorkingValues.put(PREF_RESOURCE_FILTER, fResourceFilterField.getText()); IStatus status= validateResourceFilters();
11,826
Bug 11826 Build exclusion filter should be trimmed prior to storing
null
resolved fixed
574cdab
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:42:21Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/JavaBuilderPreferencePage.java
updateStatus(status); } private IStatus validateResourceFilters() { IWorkspace workspace= ResourcesPlugin.getWorkspace(); String text= fResourceFilterField.getText(); StringTokenizer tok= new StringTokenizer(text, ","); while (tok.hasMoreTokens()) { String curr= tok.nextToken().trim(); String fileName= curr.replace('*', 'x'); IStatus status= workspace.validateName(fileName, IResource.FILE); if (status.matches(IStatus.ERROR)) { String message= JavaUIMessages.getFormattedString("JavaBuilderPreferencePage.filter.invalidsegment.error", status.getMessage()); return new StatusInfo(IStatus.ERROR, message); } } return new StatusInfo(); } private void updateStatus(IStatus status) { setValid(!status.matches(IStatus.ERROR)); StatusUtil.applyToStatusLine(this, status); } private void doFullBuild() { ProgressMonitorDialog dialog= new ProgressMonitorDialog(getShell()); try { dialog.run(true, true, new IRunnableWithProgress() { public void run(IProgressMonitor monitor) throws InvocationTargetException { try {
11,826
Bug 11826 Build exclusion filter should be trimmed prior to storing
null
resolved fixed
574cdab
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-22T19:42:21Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/JavaBuilderPreferencePage.java
JavaPlugin.getWorkspace().build(IncrementalProjectBuilder.FULL_BUILD, monitor); } catch (CoreException e) { throw new InvocationTargetException(e); } } }); } catch (InterruptedException e) { } catch (InvocationTargetException e) { String title= JavaUIMessages.getString("JavaBuilderPreferencePage.builderror.title"); String message= JavaUIMessages.getString("JavaBuilderPreferencePage.builderror.message"); ExceptionHandler.handle(e, getShell(), title, message); } } /* * @see PreferencePage#performDefaults() */ protected void performDefaults() { fWorkingValues= JavaCore.getDefaultOptions(); updateControls(); doValidation(); super.performDefaults(); } private void updateControls() { fResourceFilterField.setText((String) fWorkingValues.get(PREF_RESOURCE_FILTER)); } }
11,828
Bug 11828 Can cause NPE: Open Recent... is active when no perspective is open
1. open 2 java files (A and B) 2. close all perspectives 3. Open Recent... (should be diabled) 4. Open file A 5. Open file B ==> icons appear in the toolbar Click next error ==> NPE Log: Wed Mar 20 14:11:39 GMT+01:00 2002 2 org.eclipse.ui 2 Problems occurred when invoking code from plug-in: org.eclipse.ui. java.lang.NullPointerException at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider.update(JavaInformationProvider.java:89) at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider$EditorWatcher.partActivated(JavaInformationProvider.java:54) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WWinPartService.partActivated(WWinPartService.java:102) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WorkbenchPage.firePartActivated(WorkbenchPage.java:696) at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:1683) at org.eclipse.ui.internal.WorkbenchPage.activate(WorkbenchPage.java:103) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1277) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1254) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1246) at org.eclipse.ui.internal.ReopenEditorMenu.open(ReopenEditorMenu.java:195) at org.eclipse.ui.internal.ReopenEditorMenu$1.widgetSelected(ReopenEditorMenu.java:163) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:85) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) Log: Wed Mar 20 14:11:40 GMT+01:00 2002 1 org.eclipse.core.resources 4 Unhandled exception caught in event loop. Log: Wed Mar 20 14:11:40 GMT+01:00 2002 4 org.eclipse.ui 0 java.lang.NullPointerException java.lang.NullPointerException at org.eclipse.jdt.internal.ui.javaeditor.GotoErrorAction.run(GotoErrorAction.java:32) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent(ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0(ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52)
closed fixed
6e927a6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T10:49:08Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/JavaInformationProvider.java
package org.eclipse.jdt.internal.ui.text.java.hover; /* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ import org.eclipse.jface.text.IRegion; import org.eclipse.jface.text.ITextHover; import org.eclipse.jface.text.ITextViewer; import org.eclipse.jface.text.information.IInformationProvider; import org.eclipse.ui.IEditorPart; import org.eclipse.ui.IPartListener; import org.eclipse.ui.IWorkbenchPage; import org.eclipse.ui.IWorkbenchPart; import org.eclipse.ui.IWorkbenchWindow; import org.eclipse.jdt.internal.ui.text.JavaWordFinder; import org.eclipse.jdt.ui.*; import org.eclipse.jdt.ui.text.java.hover.*; public class JavaInformationProvider implements IInformationProvider { class EditorWatcher implements IPartListener { /** * @see IPartListener#partOpened(IWorkbenchPart) */ public void partOpened(IWorkbenchPart part) { }
11,828
Bug 11828 Can cause NPE: Open Recent... is active when no perspective is open
1. open 2 java files (A and B) 2. close all perspectives 3. Open Recent... (should be diabled) 4. Open file A 5. Open file B ==> icons appear in the toolbar Click next error ==> NPE Log: Wed Mar 20 14:11:39 GMT+01:00 2002 2 org.eclipse.ui 2 Problems occurred when invoking code from plug-in: org.eclipse.ui. java.lang.NullPointerException at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider.update(JavaInformationProvider.java:89) at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider$EditorWatcher.partActivated(JavaInformationProvider.java:54) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WWinPartService.partActivated(WWinPartService.java:102) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WorkbenchPage.firePartActivated(WorkbenchPage.java:696) at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:1683) at org.eclipse.ui.internal.WorkbenchPage.activate(WorkbenchPage.java:103) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1277) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1254) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1246) at org.eclipse.ui.internal.ReopenEditorMenu.open(ReopenEditorMenu.java:195) at org.eclipse.ui.internal.ReopenEditorMenu$1.widgetSelected(ReopenEditorMenu.java:163) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:85) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) Log: Wed Mar 20 14:11:40 GMT+01:00 2002 1 org.eclipse.core.resources 4 Unhandled exception caught in event loop. Log: Wed Mar 20 14:11:40 GMT+01:00 2002 4 org.eclipse.ui 0 java.lang.NullPointerException java.lang.NullPointerException at org.eclipse.jdt.internal.ui.javaeditor.GotoErrorAction.run(GotoErrorAction.java:32) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent(ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0(ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52)
closed fixed
6e927a6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T10:49:08Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/JavaInformationProvider.java
/** * @see IPartListener#partDeactivated(IWorkbenchPart) */ public void partDeactivated(IWorkbenchPart part) { } /** * @see IPartListener#partClosed(IWorkbenchPart) */ public void partClosed(IWorkbenchPart part) { if (part == fEditor) { fEditor.getSite().getWorkbenchWindow().getPartService().removePartListener(fPartListener); fPartListener= null; } } /** * @see IPartListener#partActivated(IWorkbenchPart) */ public void partActivated(IWorkbenchPart part) { update(); } public void partBroughtToTop(IWorkbenchPart part) { update(); } }; protected IEditorPart fEditor;
11,828
Bug 11828 Can cause NPE: Open Recent... is active when no perspective is open
1. open 2 java files (A and B) 2. close all perspectives 3. Open Recent... (should be diabled) 4. Open file A 5. Open file B ==> icons appear in the toolbar Click next error ==> NPE Log: Wed Mar 20 14:11:39 GMT+01:00 2002 2 org.eclipse.ui 2 Problems occurred when invoking code from plug-in: org.eclipse.ui. java.lang.NullPointerException at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider.update(JavaInformationProvider.java:89) at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider$EditorWatcher.partActivated(JavaInformationProvider.java:54) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WWinPartService.partActivated(WWinPartService.java:102) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WorkbenchPage.firePartActivated(WorkbenchPage.java:696) at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:1683) at org.eclipse.ui.internal.WorkbenchPage.activate(WorkbenchPage.java:103) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1277) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1254) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1246) at org.eclipse.ui.internal.ReopenEditorMenu.open(ReopenEditorMenu.java:195) at org.eclipse.ui.internal.ReopenEditorMenu$1.widgetSelected(ReopenEditorMenu.java:163) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:85) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) Log: Wed Mar 20 14:11:40 GMT+01:00 2002 1 org.eclipse.core.resources 4 Unhandled exception caught in event loop. Log: Wed Mar 20 14:11:40 GMT+01:00 2002 4 org.eclipse.ui 0 java.lang.NullPointerException java.lang.NullPointerException at org.eclipse.jdt.internal.ui.javaeditor.GotoErrorAction.run(GotoErrorAction.java:32) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent(ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0(ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52)
closed fixed
6e927a6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T10:49:08Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/JavaInformationProvider.java
protected IPartListener fPartListener; protected String fCurrentPerspective; protected IJavaEditorTextHover fImplementation; public JavaInformationProvider(IEditorPart editor) { fEditor= editor; if (fEditor != null) { fPartListener= new EditorWatcher(); IWorkbenchWindow window= fEditor.getSite().getWorkbenchWindow(); window.getPartService().addPartListener(fPartListener); update(); } } protected void update() { IWorkbenchWindow window= fEditor.getSite().getWorkbenchWindow(); IWorkbenchPage page= window.getActivePage(); if (page != null) { String newPerspective= page.getPerspective().getId(); if (fCurrentPerspective == null || fCurrentPerspective != newPerspective) { fCurrentPerspective= newPerspective;
11,828
Bug 11828 Can cause NPE: Open Recent... is active when no perspective is open
1. open 2 java files (A and B) 2. close all perspectives 3. Open Recent... (should be diabled) 4. Open file A 5. Open file B ==> icons appear in the toolbar Click next error ==> NPE Log: Wed Mar 20 14:11:39 GMT+01:00 2002 2 org.eclipse.ui 2 Problems occurred when invoking code from plug-in: org.eclipse.ui. java.lang.NullPointerException at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider.update(JavaInformationProvider.java:89) at org.eclipse.jdt.internal.ui.text.java.hover.JavaInformationProvider$EditorWatcher.partActivated(JavaInformationProvider.java:54) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WWinPartService.partActivated(WWinPartService.java:102) at org.eclipse.ui.internal.PartListenerList$1.run(PartListenerList.java:37) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:817) at org.eclipse.core.runtime.Platform.run(Platform.java:395) at org.eclipse.ui.internal.PartListenerList.firePartActivated(PartListenerList.java:35) at org.eclipse.ui.internal.WorkbenchPage.firePartActivated(WorkbenchPage.java:696) at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:1683) at org.eclipse.ui.internal.WorkbenchPage.activate(WorkbenchPage.java:103) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1277) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1254) at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:1246) at org.eclipse.ui.internal.ReopenEditorMenu.open(ReopenEditorMenu.java:195) at org.eclipse.ui.internal.ReopenEditorMenu$1.widgetSelected(ReopenEditorMenu.java:163) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:85) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) Log: Wed Mar 20 14:11:40 GMT+01:00 2002 1 org.eclipse.core.resources 4 Unhandled exception caught in event loop. Log: Wed Mar 20 14:11:40 GMT+01:00 2002 4 org.eclipse.ui 0 java.lang.NullPointerException java.lang.NullPointerException at org.eclipse.jdt.internal.ui.javaeditor.GotoErrorAction.run(GotoErrorAction.java:32) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:407) at org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent(ActionContributionItem.java:361) at org.eclipse.jface.action.ActionContributionItem.access$0(ActionContributionItem.java:352) at org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java:47) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code)) at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java(Compiled Code)) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code)) at org.eclipse.ui.internal.Workbench.run(Workbench.java:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52)
closed fixed
6e927a6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T10:49:08Z
2002-03-20T13:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/JavaInformationProvider.java
fImplementation= new JavaTypeHover(); fImplementation.setEditor(fEditor); } } } /* * @see IInformationProvider#getSubject(ITextViewer, int) */ public IRegion getSubject(ITextViewer textViewer, int offset) { if (textViewer != null) return JavaWordFinder.findWord(textViewer.getDocument(), offset); return null; } /* * @see IInformationProvider#getInformation(ITextViewer, IRegion) */ public String getInformation(ITextViewer textViewer, IRegion subject) { if (fImplementation != null) { String s= fImplementation.getHoverInfo(textViewer, subject); if (s != null && s.trim().length() > 0) return s; } return null; } }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
package org.eclipse.jdt.junit.wizards; import java.util.ArrayList; import java.util.HashMap; import java.util.ListIterator; import org.eclipse.core.resources.IMarker; import org.eclipse.core.resources.IResource; import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IStatus; import org.eclipse.jdt.core.Flags; import org.eclipse.jdt.core.ICompilationUnit; import org.eclipse.jdt.core.IJavaElement; import org.eclipse.jdt.core.IJavaProject; import org.eclipse.jdt.core.IMethod; import org.eclipse.jdt.core.IPackageFragment; import org.eclipse.jdt.core.IPackageFragmentRoot; import org.eclipse.jdt.core.ISourceRange; import org.eclipse.jdt.core.IType; import org.eclipse.jdt.core.ITypeHierarchy; import org.eclipse.jdt.core.JavaConventions; import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.core.Signature; import org.eclipse.jdt.core.search.IJavaSearchScope; import org.eclipse.jdt.core.search.SearchEngine; import org.eclipse.jdt.internal.corext.codemanipulation.CodeGenerationSettings; import org.eclipse.jdt.internal.corext.codemanipulation.IImportsStructure;
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
import org.eclipse.jdt.internal.corext.util.JavaModelUtil; import org.eclipse.jdt.internal.junit.ui.JUnitPlugin; import org.eclipse.jdt.internal.junit.util.JUnitStatus; import org.eclipse.jdt.internal.junit.util.JUnitStubUtility; import org.eclipse.jdt.internal.junit.util.LayoutUtil; import org.eclipse.jdt.internal.junit.util.TestSearchEngine; import org.eclipse.jdt.internal.junit.util.JUnitStubUtility.GenStubSettings; import org.eclipse.jdt.internal.ui.preferences.JavaPreferencesSettings; import org.eclipse.jdt.internal.ui.util.SWTUtil; import org.eclipse.jdt.ui.IJavaElementSearchConstants; import org.eclipse.jdt.ui.JavaUI; import org.eclipse.jdt.ui.wizards.NewTypeWizardPage; import org.eclipse.jface.viewers.IStructuredSelection; import org.eclipse.swt.SWT; import org.eclipse.swt.events.ModifyEvent; import org.eclipse.swt.events.ModifyListener; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.events.SelectionListener; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Text; import org.eclipse.ui.dialogs.SelectionDialog; /** * The first page of the TestCase creation wizard. */ public class NewTestCaseCreationWizardPage extends NewTypeWizardPage {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
protected final static String PAGE_NAME= "NewTestCaseCreationWizardPage"; protected final static String CLASS_TO_TEST= PAGE_NAME + ".classtotest"; protected final static String TEST_CLASS= PAGE_NAME + ".testclass"; protected final static String TEST_SUFFIX= "Test"; protected final static String SETUP= "setUp";
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
protected final static String TEARDOWN= "tearDown"; private String fDefaultClassToTest; private NewTestCaseCreationWizardPage2 fPage2; private SelectionButtonGroup fMethodStubsButtons; private IType fClassToTest; protected IStatus fClassToTestStatus; protected IStatus fTestClassStatus; private int fIndexOfFirstTestMethod; private Label fClassToTestLabel; private Text fClassToTestText; private Button fClassToTestButton; private Label fTestClassLabel; private Text fTestClassText; private String fTestClassTextInitialValue; private IMethod[] fTestMethods; private IType fCreatedType; private boolean fFirstTime; public NewTestCaseCreationWizardPage() { super(true, PAGE_NAME); fFirstTime= true; fTestClassTextInitialValue= ""; setTitle(Messages.getString("NewTestClassWizPage.title")); setDescription(Messages.getString("NewTestClassWizPage.description")); String[] buttonNames= new String[] { "public static void main(Strin&g[] args)",
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
Messages.getString("NewTestClassWizPage.methodStub.testRunner"), Messages.getString("NewTestClassWizPage.methodStub.setUp"), Messages.getString("NewTestClassWizPage.methodStub.tearDown") }; fMethodStubsButtons= new SelectionButtonGroup(SWT.CHECK, buttonNames, 1); fMethodStubsButtons.setLabelText(Messages.getString("NewTestClassWizPage.method.Stub.label")); fMethodStubsButtons.setSelectionGroupListener(new SelectionButtonGroup.SelectionButtonGroupListener() { public void groupChanged(SelectionButtonGroup field) { field.setEnabled(1, field.isSelected(0)); } }); fClassToTestStatus= new JUnitStatus(); fTestClassStatus= new JUnitStatus(); fDefaultClassToTest= ""; } /** * Should be called from the wizard with the input element. */ public void init(IStructuredSelection selection, NewTestCaseCreationWizardPage2 page2) { fPage2= page2; IJavaElement element= getInitialJavaElement(selection); initContainerPage(element); initTypePage(element); updateStatus(findMostSevereStatus()); if (element != null) {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
IType enclosingType= null; IPackageFragment pack= (IPackageFragment) JavaModelUtil.findElementOfKind(element, IJavaElement.PACKAGE_FRAGMENT); IType typeInCompUnit= (IType) JavaModelUtil.findElementOfKind(element, IJavaElement.TYPE); if (typeInCompUnit != null) { if (typeInCompUnit.getCompilationUnit() != null) { enclosingType= typeInCompUnit; } } else { ICompilationUnit cu= (ICompilationUnit) JavaModelUtil.findElementOfKind(element, IJavaElement.COMPILATION_UNIT); if (cu != null) enclosingType= JavaModelUtil.findPrimaryType(cu); } if (enclosingType != null) { try { if (!TestSearchEngine.isTestImplementor(enclosingType)) { fDefaultClassToTest= enclosingType.getFullyQualifiedName(); } } catch (JavaModelException e) { e.printStackTrace(); } } } fMethodStubsButtons.setSelection(0, false); fMethodStubsButtons.setSelection(1, false); fMethodStubsButtons.setEnabled(1, false); fMethodStubsButtons.setSelection(2, false); fMethodStubsButtons.setSelection(3, false); }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
/** * Finds the most severe error (if there is one) */ private IStatus findMostSevereStatus() { return NewTestCaseCreationWizardPage.getMostSevere(new IStatus[] { fContainerStatus, fPackageStatus, fTestClassStatus, fClassToTestStatus, fModifierStatus, fSuperClassStatus }); } /* * @see ContainerPage#handleFieldChanged */ protected void handleFieldChanged(String fieldName) { super.handleFieldChanged(fieldName); if (fieldName.equals(CLASS_TO_TEST)) { fClassToTestStatus= classToTestClassChanged(); updateDefaultName(); } else if (fieldName.equals(SUPER)) { validateSuperClass(); } else if (fieldName.equals(TEST_CLASS)) { fTestClassStatus= testClassChanged(); } else if (fieldName.equals(PACKAGE) || fieldName.equals(CONTAINER)) { if (fieldName.equals(PACKAGE)) fPackageStatus= packageChanged(); if (!fFirstTime) { validateSuperClass();
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
fClassToTestStatus= classToTestClassChanged(); fTestClassStatus= testClassChanged(); } } updateStatus(findMostSevereStatus()); } protected void updateDefaultName() { String s= fClassToTestText.getText(); if (s.lastIndexOf('.') > -1) s= s.substring(s.lastIndexOf('.') + 1); if (s.length() > 0) setTypeName(s + TEST_SUFFIX, true); } /* * @see IDialogPage#createControl(Composite) */ public void createControl(Composite parent) { initializeDialogUnits(parent); Composite composite= new Composite(parent, SWT.NONE); int nColumns= 4; GridLayout layout= new GridLayout(); layout.numColumns= nColumns; composite.setLayout(layout); createContainerControls(composite, nColumns); createPackageControls(composite, nColumns); createSeparator(composite, nColumns);
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
createTestClassControls(composite, nColumns); createClassToTestControls(composite, nColumns); createSuperClassControls(composite, nColumns); createMethodStubSelectionControls(composite, nColumns); setSuperClass(JUnitPlugin.TEST_SUPERCLASS_NAME, true); setControl(composite); fClassToTestText.setText(fDefaultClassToTest); setFocus(); } protected void createMethodStubSelectionControls(Composite composite, int nColumns) { LayoutUtil.setHorizontalSpan(fMethodStubsButtons.getLabelControl(composite), nColumns); LayoutUtil.createEmptySpace(composite,1); LayoutUtil.setHorizontalSpan(fMethodStubsButtons.getSelectionButtonsGroup(composite), nColumns - 1); } protected void createClassToTestControls(Composite composite, int nColumns) { fClassToTestLabel= new Label(composite, SWT.LEFT | SWT.WRAP); fClassToTestLabel.setFont(composite.getFont()); fClassToTestLabel.setText(Messages.getString("NewTestClassWizPage.class_to_test.label")); GridData gd= new GridData(); gd.horizontalSpan= 1; fClassToTestLabel.setLayoutData(gd); fClassToTestText= new Text(composite, SWT.SINGLE | SWT.BORDER); fClassToTestText.setEnabled(true); fClassToTestText.setFont(composite.getFont()); fClassToTestText.addModifyListener(new ModifyListener() { public void modifyText(ModifyEvent e) { handleFieldChanged(CLASS_TO_TEST);
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
} }); gd= new GridData(); gd.horizontalAlignment= gd.FILL; gd.grabExcessHorizontalSpace= true; gd.horizontalSpan= nColumns - 2; fClassToTestText.setLayoutData(gd); fClassToTestButton= new Button(composite, SWT.PUSH); fClassToTestButton.setText(Messages.getString("NewTestClassWizPage.class_to_test.browse")); fClassToTestButton.setEnabled(true); fClassToTestButton.addSelectionListener(new SelectionListener() { public void widgetDefaultSelected(SelectionEvent e) { classToTestButtonPressed(); } public void widgetSelected(SelectionEvent e) { classToTestButtonPressed(); } }); gd= new GridData(); gd.horizontalAlignment= gd.FILL; gd.grabExcessHorizontalSpace= false; gd.horizontalSpan= 1; gd.heightHint = SWTUtil.getButtonHeigthHint(fClassToTestButton); gd.widthHint = SWTUtil.getButtonWidthHint(fClassToTestButton); fClassToTestButton.setLayoutData(gd); } private void classToTestButtonPressed() { IType type= chooseClassToTestType(); if (type != null) {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
fClassToTestText.setText(JavaModelUtil.getFullyQualifiedName(type)); handleFieldChanged(CLASS_TO_TEST); } } private IType chooseClassToTestType() { IPackageFragmentRoot root= getPackageFragmentRoot(); if (root == null) return null; IJavaElement[] elements= new IJavaElement[] { root.getJavaProject() }; IJavaSearchScope scope= SearchEngine.createJavaSearchScope(elements); IType type= null; try { SelectionDialog dialog= JavaUI.createTypeDialog(getShell(), getWizard().getContainer(), scope, IJavaElementSearchConstants.CONSIDER_CLASSES, false, null); dialog.setTitle(Messages.getString("NewTestClassWizPage.class_to_test.dialog.title")); dialog.setMessage(Messages.getString("NewTestClassWizPage.class_to_test.dialog.message")); dialog.open(); if (dialog.getReturnCode() != SelectionDialog.OK) return type; else { Object[] resultArray= dialog.getResult(); type= (IType) resultArray[0]; } } catch (JavaModelException e) { } return type; } protected IStatus classToTestClassChanged() { fClassToTestButton.setEnabled(getPackageFragmentRoot() != null);
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
IStatus status= validateClassToTest(); return status; } /** * Gets the content of the class to test text field. */ public String getClassToTestText() { return fClassToTestText.getText(); } public IType getClassToTest() { return fClassToTest; } /** * Sets the class to test name. * @param canBeModified Selects if the super class can be changed by the user */ public void setClassToTest(String name) { fClassToTestText.setText(name); } /* * @see TypePage#evalMethods */ protected void createTypeMembers(IType type, IImportsStructure imports, IProgressMonitor monitor) throws CoreException { fIndexOfFirstTestMethod= 0; createConstructor(type); if (fMethodStubsButtons.isSelected(0)) createMain(type); if (fMethodStubsButtons.isSelected(2)) {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
createSetUp(type, imports); } if (fMethodStubsButtons.isSelected(3)) { createTearDown(type, imports); } if (isNextPageValid()) { createTestMethodStubs(type); } } protected void createConstructor(IType type) throws JavaModelException { String constr= "public "+getTypeName()+"(String name) {super(name);}\n\n"; type.createMethod(constr, null, false, null); fIndexOfFirstTestMethod++; } protected void createMain(IType type) throws JavaModelException { StringBuffer main= new StringBuffer("public static void main(String[] args) {"); if (fMethodStubsButtons.isSelected(1)) { main.append("junit."); switch (fMethodStubsButtons.getComboSelection()) { case 0: main.append("textui"); break; case 1: main.append("swingui"); break; case 2 : main.append("awtui"); break;
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
default : main.append("textui"); break; } main.append(".TestRunner.run(" + getTypeName() + ".class);"); } main.append("}\n"); type.createMethod(main.toString(), null, false, null); fIndexOfFirstTestMethod++; } protected void createSetUp(IType type, IImportsStructure imports) throws JavaModelException { ITypeHierarchy typeHierarchy= null; IType[] superTypes= null; String setUp; IMethod methodTemplate= null; if (type.exists()) { typeHierarchy= type.newSupertypeHierarchy(null); superTypes= typeHierarchy.getAllSuperclasses(type); for (int i= 0; i < superTypes.length; i++) { if (superTypes[i].exists()) { IMethod testMethod= superTypes[i].getMethod(SETUP, new String[] {}); if (testMethod.exists()) { methodTemplate= testMethod; break; } } } } if (methodTemplate != null) { CodeGenerationSettings settings= JavaPreferencesSettings.getCodeGenerationSettings();
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
GenStubSettings genStubSettings= new GenStubSettings(settings); genStubSettings.fCallSuper= true; genStubSettings.fMethodOverwrites= true; setUp= JUnitStubUtility.genStub(getTypeName(), methodTemplate, genStubSettings, imports); } else { setUp="/**\n * Sets up the fixture, for example, open a network connection.\n * This method is called before a test is executed.\n * @throws Exception\n */\n" + "protected void "+SETUP+"() throws Exception {}\n\n"; } type.createMethod(setUp, null, false, null); fIndexOfFirstTestMethod++; } protected void createTearDown(IType type, IImportsStructure imports) throws JavaModelException { ITypeHierarchy typeHierarchy= null; IType[] superTypes= null; String tearDown; IMethod methodTemplate= null; if (type.exists()) { if (typeHierarchy == null) { typeHierarchy= type.newSupertypeHierarchy(null); superTypes= typeHierarchy.getAllSuperclasses(type); } for (int i= 0; i < superTypes.length; i++) { if (superTypes[i].exists()) { IMethod testM= superTypes[i].getMethod(TEARDOWN, new String[] {}); if (testM.exists()) { methodTemplate= testM; break; } }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
} } if (methodTemplate != null) { CodeGenerationSettings settings= JavaPreferencesSettings.getCodeGenerationSettings(); GenStubSettings genStubSettings= new GenStubSettings(settings); genStubSettings.fCallSuper= true; genStubSettings.fMethodOverwrites= true; tearDown= JUnitStubUtility.genStub(getTypeName(), methodTemplate, genStubSettings, imports); } else { tearDown="/**\n * Tears down the fixture, for example, close a network connection.\n * This method is called after a test is executed.\n * @throws Exception\n */\n" + "protected void "+TEARDOWN+"() throws Exception {}\n\n"; } type.createMethod(tearDown, null, false, null); fIndexOfFirstTestMethod++; } protected void createTestMethodStubs(IType type) throws JavaModelException { IMethod[] methods= fPage2.getCheckedMethods(); if (methods.length > 0) { ArrayList allMethods= new ArrayList(); IMethod[] allMethodsArray= fPage2.getAllMethods(); for (int i= 0; i < allMethodsArray.length; i++) { allMethods.add(allMethodsArray[i]); } ArrayList overloadedMethods= new ArrayList(); for (int i= 0; i < allMethods.size(); i++) { IMethod current= (IMethod) allMethods.get(i); String currentName= current.getElementName(); boolean currentAdded= false; for (ListIterator iter= allMethods.listIterator(i+1); iter.hasNext(); ) {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
IMethod iterMethod= (IMethod) iter.next(); if (iterMethod.getElementName().equals(currentName)) { if (!currentAdded) { overloadedMethods.add(current); currentAdded= true; } overloadedMethods.add(iterMethod); iter.remove(); } } } /* used when for example both sum and Sum methods are present. Then * sum -> testSum * Sum -> testSum1 */ ArrayList newMethodsNames= new ArrayList(); for (int i = 0; i < methods.length; i++) { String elementName= methods[i].getElementName(); StringBuffer methodName= new StringBuffer(NewTestCaseCreationWizardPage2.PREFIX+Character.toUpperCase(elementName.charAt(0))+elementName.substring(1)); StringBuffer newMethod= new StringBuffer(); if (overloadedMethods.contains(methods[i])) { IMethod method= methods[i]; newMethod.append("/*\n * Test for "+Signature.toString(method.getReturnType())+" "+method.getElementName()+"("); String[] paramTypes= method.getParameterTypes(); if (paramTypes.length > 0) { if (paramTypes.length > 1) { for (int j= 0; j < paramTypes.length-1; j++) {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
newMethod.append(Signature.toString(paramTypes[j])+", "); } } newMethod.append(Signature.toString(paramTypes[paramTypes.length-1])); } newMethod.append(")\n */\n"); String[] params= methods[i].getParameterTypes(); for (int j= 0; j < params.length; j++) { String param= params[j]; int start= 0, end= param.length(); if (param.startsWith( (new Character(Signature.C_ARRAY)).toString() )) start= 1; methodName.append(param.substring( ((param.startsWith( (new Character(Signature.C_UNRESOLVED)).toString() ,start))?start+1:start) , ((param.endsWith( (new Character(Signature.C_NAME_END)).toString() ))?end-1:end)) ); if (param.startsWith( (new Character(Signature.C_ARRAY)).toString() )) methodName.append("Array"); } } if (newMethodsNames.contains(methodName.toString())) methodName.append("1"); newMethodsNames.add(new String(methodName)); newMethod.append("public void "+methodName.toString()+"() {}\n\n"); type.createMethod(newMethod.toString(), null, false, null); }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
} } protected static GridData gridDataForDefaultForTypeName(int span) { GridData gd= new GridData(); gd.horizontalSpan= span; return gd; } public static Control createEmptySpace(Composite parent, int span) { Label label= new Label(parent, SWT.LEFT); GridData gd= new GridData(); gd.horizontalAlignment= gd.BEGINNING; gd.grabExcessHorizontalSpace= false; gd.horizontalSpan= span; gd.horizontalIndent= 0; gd.widthHint= 0; gd.heightHint= 0; label.setLayoutData(gd); return label; } public void setVisible(boolean visible) { super.setVisible(visible); if (visible && fFirstTime) { handleFieldChanged(CLASS_TO_TEST); fFirstTime= false; } } public int getIndexOfFirstMethod() { return fIndexOfFirstTestMethod; }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
/** * Creates a type using the current field values. */ public void createType(IProgressMonitor monitor) throws CoreException, InterruptedException { super.createType(monitor); if (fPage2.getCreateTasksButtonSelection()) { createTaskMarkers(); } } private void createTaskMarkers() throws CoreException { IType createdType= getCreatedType(); fTestMethods= createdType.getMethods(); ICompilationUnit cu= createdType.getCompilationUnit(); cu.save(null, false); IResource res= createdType.getCompilationUnit().getUnderlyingResource(); for (int i= getIndexOfFirstMethod(); i < fTestMethods.length; i++) { IMethod method= fTestMethods[i]; IMarker marker= res.createMarker("org.eclipse.jdt.junit.junit_task"); HashMap attributes= new HashMap(10); attributes.put(IMarker.PRIORITY, new Integer(IMarker.PRIORITY_NORMAL)); attributes.put(IMarker.MESSAGE, Messages.getFormattedString("NewTestClassWizPage.marker.message",method.getElementName())); ISourceRange markerRange= method.getSourceRange(); attributes.put(IMarker.CHAR_START, new Integer(markerRange.getOffset())); attributes.put(IMarker.CHAR_END, new Integer(markerRange.getOffset()+markerRange.getLength())); marker.setAttributes(attributes); } } private void validateSuperClass() { fMethodStubsButtons.setEnabled(2, true);
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
fMethodStubsButtons.setEnabled(3, true); String superClassName= getSuperClass(); if (superClassName != null && !superClassName.equals("") && getPackageFragmentRoot() != null) { try { IType type= NewTestCaseCreationWizardPage.resolveClassNameToType(getPackageFragmentRoot().getJavaProject(), getPackageFragment(), superClassName); JUnitStatus status = new JUnitStatus(); if (type == null) { status.setError(Messages.getString("NewTestClassWizPage.error.superclass.not_exist")); fSuperClassStatus= status; } else { if (type.isInterface()) { status.setError(Messages.getString("NewTestClassWizPage.error.superclass.is_interface")); fSuperClassStatus= status; } if (!TestSearchEngine.isTestImplementor(type)) { status.setError(Messages.getFormattedString("NewTestClassWizPage.error.superclass.not_implementing_test_interface", JUnitPlugin.TEST_INTERFACE_NAME)); fSuperClassStatus= status; } else { IMethod setupMethod= type.getMethod(SETUP, new String[] {}); IMethod teardownMethod= type.getMethod(TEARDOWN, new String[] {}); if (setupMethod.exists()) fMethodStubsButtons.setEnabled(2, !Flags.isFinal(setupMethod.getFlags())); if (teardownMethod.exists()) fMethodStubsButtons.setEnabled(3, !Flags.isFinal(teardownMethod.getFlags())); } } } catch (JavaModelException e) { System.err.println(this.getClass()+": checkSuperClass(): "+e); } }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
} protected void createTestClassControls(Composite composite, int nColumns) { fTestClassLabel= new Label(composite, SWT.LEFT | SWT.WRAP); fTestClassLabel.setFont(composite.getFont()); fTestClassLabel.setText(Messages.getString("NewTestClassWizPage.testcase.label")); GridData gd= new GridData(); gd.horizontalSpan= 1; fTestClassLabel.setLayoutData(gd); fTestClassText= new Text(composite, SWT.SINGLE | SWT.BORDER); fTestClassText.setEnabled(true); fTestClassText.setFont(composite.getFont()); fTestClassText.addModifyListener(new ModifyListener() { public void modifyText(ModifyEvent e) { handleFieldChanged(TEST_CLASS); } }); gd= new GridData(); gd.horizontalAlignment= gd.FILL; gd.grabExcessHorizontalSpace= true; gd.horizontalSpan= nColumns - 2; fTestClassText.setLayoutData(gd); Label space= new Label(composite, SWT.LEFT); space.setText(" "); gd= new GridData(); gd.horizontalSpan= 1; space.setLayoutData(gd); } /**
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
* Gets the type name. */ public String getTypeName() { return (fTestClassText==null)?fTestClassTextInitialValue:fTestClassText.getText(); } /** * Sets the type name. */ public void setTypeName(String name, boolean canBeModified) { if (fTestClassText == null) { fTestClassTextInitialValue= name; } else { fTestClassText.setText(name); fTestClassText.setEnabled(canBeModified); } } /** * Called when the type name has changed. * The method validates the type name and returns the status of the validation. * Can be extended to add more validation */ protected IStatus testClassChanged() { JUnitStatus status= new JUnitStatus(); String typeName= getTypeName(); if (typeName.length() == 0) { status.setError(Messages.getString("NewTestClassWizPage.error.testcase.name_empty")); return status;
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
} if (typeName.indexOf('.') != -1) { status.setError(Messages.getString("NewTestClassWizPage.error.testcase.name_qualified")); return status; } IStatus val= JavaConventions.validateJavaTypeName(typeName); if (val.getSeverity() == IStatus.ERROR) { status.setError(Messages.getString("NewTestClassWizPage.error.testcase.name_not_valid")+val.getMessage()); return status; } else if (val.getSeverity() == IStatus.WARNING) { status.setWarning(Messages.getString("NewTestClassWizPage.error.testcase.name_discouraged")+val.getMessage()); } IPackageFragment pack= getPackageFragment(); if (pack != null) { ICompilationUnit cu= pack.getCompilationUnit(typeName + ".java"); if (cu.exists()) { status.setError(Messages.getString("NewTestClassWizPage.error.testcase.already_exists")); return status; } } return status; } /** * @see WizardPage#getNextPage */ public boolean canFlipToNextPage() { return isPageComplete() && getNextPage() != null && isNextPageValid(); }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
protected boolean isNextPageValid() { return !getClassToTestText().equals(""); } protected JUnitStatus validateClassToTest() { IPackageFragmentRoot root= getPackageFragmentRoot(); IPackageFragment pack= getPackageFragment(); String classToTestName= fClassToTestText.getText(); JUnitStatus status= new JUnitStatus(); fClassToTest= null; if (classToTestName.length() == 0) { return status; } IStatus val= JavaConventions.validateJavaTypeName(classToTestName); if (!val.isOK()) { status.setError(Messages.getString("NewTestClassWizPage.error.class_to_test.not_valid")); return status; } if (root != null) { try { IType type= NewTestCaseCreationWizardPage.resolveClassNameToType(root.getJavaProject(), pack, classToTestName); if (type == null) { status.setError(Messages.getString("NewTestClassWizPage.error.class_to_test.not_exist")); return status; } else { if (type.isInterface()) { status.setWarning(Messages.getFormattedString("NewTestClassWizPage.warning.class_to_test.is_interface",classToTestName));
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
return status; } if (pack != null && !JavaModelUtil.isVisible(type, pack)) { status.setWarning(Messages.getFormattedString("NewTestClassWizPage.warning.class_to_test.interface_not_visible",classToTestName)); return status; } } fClassToTest= type; } catch (JavaModelException e) { status.setError(Messages.getString("NewTestClassWizPage.error.class_to_test.not_valid")); } } else { status.setError(""); } return status; } static public IType resolveClassNameToType(IJavaProject jproject, IPackageFragment pack, String classToTestName) throws JavaModelException { IType type= null; if (type == null && pack != null) { String packName= pack.getElementName(); if (!pack.isDefaultPackage()) { type= JavaModelUtil.findType(jproject, packName, classToTestName); } if (type == null && !"java.lang".equals(packName)) { type= JavaModelUtil.findType(jproject, "java.lang", classToTestName); } }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage.java
if (type == null) { type= JavaModelUtil.findType(jproject, classToTestName); } return type; } /** * Finds the most severe status from a array of stati. * An error is more severe than a warning, and a warning is more severe * than ok. */ public static IStatus getMostSevere(IStatus[] status) { IStatus max= null; for (int i= 0; i < status.length; i++) { IStatus curr= status[i]; if (curr.matches(IStatus.ERROR)) { return curr; } if (max == null || curr.getSeverity() > max.getSeverity()) { max= curr; } } return max; } /** * Sets the focus on the type name. */ protected void setFocus() { fTestClassText.setFocus(); } }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
/* * (c) Copyright 2001 MyCorporation. * All Rights Reserved.
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
*/ package org.eclipse.jdt.junit.wizards; import java.util.ArrayList; import java.util.Arrays; import java.util.Vector; import org.eclipse.jdt.core.Flags; import org.eclipse.jdt.core.IMethod; import org.eclipse.jdt.core.IType; import org.eclipse.jdt.core.ITypeHierarchy; import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.internal.ui.viewsupport.ContainerCheckedTreeViewer; import org.eclipse.jdt.ui.JavaElementLabelProvider; import org.eclipse.jface.viewers.CheckStateChangedEvent; import org.eclipse.jface.viewers.ICheckStateListener; import org.eclipse.jface.viewers.ITreeContentProvider; import org.eclipse.jface.viewers.StructuredSelection; import org.eclipse.jface.viewers.Viewer; import org.eclipse.jface.wizard.WizardPage; import org.eclipse.swt.SWT; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Label; /** * Wizard page to select the methods from a class under test. */ public class NewTestCaseCreationWizardPage2 extends WizardPage {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
private final static String PAGE_NAME= "NewTestCaseCreationWizardPage2"; public final static String PREFIX= "test"; private NewTestCaseCreationWizardPage fFirstPage; private IType fClassToTest; private Button fCreateTasksButton; private ContainerCheckedTreeViewer fMethodsTree; private Button fSelectAllButton; private Button fDeselectAllButton; private Label fSelectedMethodsLabel; /** * Constructor for NewTestCaseCreationWizardPage2. */ protected NewTestCaseCreationWizardPage2(NewTestCaseCreationWizardPage firstPage) { super(PAGE_NAME); fFirstPage= firstPage; setTitle(Messages.getString("NewTestClassWizPage2.title")); setDescription(Messages.getString("NewTestClassWizPage2.description")); } /* * @see IDialogPage#createControl(Composite) */ public void createControl(Composite parent) { Composite container= new Composite(parent, SWT.NONE); GridLayout layout= new GridLayout(); layout.numColumns= 2; container.setLayout(layout); createMethodsTreeControls(container); createSpacer(container); createTasksControls(container);
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
setControl(container); } protected void createTasksControls(Composite container) { GridLayout layout; GridData gd; Composite prefixContainer= new Composite(container, SWT.NONE); gd= new GridData(); gd.horizontalAlignment = GridData.FILL; gd.horizontalSpan = 2; prefixContainer.setLayoutData(gd); layout = new GridLayout(); layout.numColumns = 2; layout.marginWidth = 0; layout.marginHeight = 0; prefixContainer.setLayout(layout); fCreateTasksButton= new Button(prefixContainer, SWT.CHECK | SWT.LEFT); fCreateTasksButton.setText(Messages.getString("NewTestClassWizPage2.create_tasks.text")); fCreateTasksButton.setEnabled(true); fCreateTasksButton.setSelection(true); gd= new GridData(); gd.horizontalAlignment= GridData.FILL; gd.horizontalSpan= 2; fCreateTasksButton.setLayoutData(gd); } protected void createMethodsTreeControls(Composite container) { Label label= new Label(container, SWT.LEFT | SWT.WRAP); label.setFont(container.getFont()); label.setText(Messages.getString("NewTestClassWizPage2.methods_tree.label"));
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
GridData gd = new GridData(); gd.horizontalSpan = 2; label.setLayoutData(gd); fMethodsTree= new ContainerCheckedTreeViewer(container, SWT.BORDER); gd= new GridData(GridData.FILL_BOTH | GridData.GRAB_HORIZONTAL | GridData.GRAB_VERTICAL); gd.heightHint= 180; fMethodsTree.getTree().setLayoutData(gd); fMethodsTree.setLabelProvider(new JavaElementLabelProvider()); fMethodsTree.setAutoExpandLevel(2); fMethodsTree.addCheckStateListener(new ICheckStateListener() { public void checkStateChanged(CheckStateChangedEvent event) { updateSelectedMethodsLabel(); } }); Composite buttonContainer= new Composite(container, SWT.NONE); gd= new GridData(GridData.FILL_VERTICAL); buttonContainer.setLayoutData(gd); GridLayout buttonLayout= new GridLayout(); buttonLayout.marginWidth= 0; buttonLayout.marginHeight= 0; buttonContainer.setLayout(buttonLayout); fSelectAllButton= new Button(buttonContainer, SWT.PUSH); fSelectAllButton.setText(Messages.getString("NewTestClassWizPage2.selectAll")); gd= new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_BEGINNING); fSelectAllButton.setLayoutData(gd); fSelectAllButton.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { fMethodsTree.setCheckedElements((Object[]) fMethodsTree.getInput()); updateSelectedMethodsLabel(); }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
}); fDeselectAllButton= new Button(buttonContainer, SWT.PUSH); fDeselectAllButton.setText(Messages.getString("NewTestClassWizPage2.deselectAll")); gd= new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_BEGINNING); fDeselectAllButton.setLayoutData(gd); fDeselectAllButton.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { fMethodsTree.setCheckedElements(new Object[0]); updateSelectedMethodsLabel(); } }); fSelectedMethodsLabel= new Label(container, SWT.LEFT); fSelectedMethodsLabel.setFont(container.getFont()); updateSelectedMethodsLabel(); gd= new GridData(GridData.FILL_HORIZONTAL); gd.horizontalSpan= 1; fSelectedMethodsLabel.setLayoutData(gd); Label emptyLabel= new Label(container, SWT.LEFT); gd= new GridData(); gd.horizontalSpan= 1; emptyLabel.setLayoutData(gd); } protected void createSpacer(Composite container) { Label spacer= new Label(container, SWT.NONE); GridData data= new GridData(); data.horizontalSpan= 2; data.horizontalAlignment= GridData.FILL; data.verticalAlignment= GridData.BEGINNING;
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
data.heightHint= 4; spacer.setLayoutData(data); } public void setVisible(boolean visible) { if (visible) { fClassToTest= fFirstPage.getClassToTest(); IType currType= fClassToTest; ArrayList types= null; try { ITypeHierarchy hierarchy= currType.newSupertypeHierarchy(null); IType[] superTypes= hierarchy.getAllSuperclasses(currType); types= new ArrayList(superTypes.length+1); types.add(currType); types.addAll(Arrays.asList(superTypes)); } catch(JavaModelException e) { } fMethodsTree.setContentProvider(new MethodsTreeContentProvider(types.toArray())); if (types == null) types= new ArrayList(); fMethodsTree.setInput(types.toArray()); fMethodsTree.setSelection(new StructuredSelection(currType), true); } updateSelectedMethodsLabel(); super.setVisible(visible); } public IMethod[] getCheckedMethods() { Object[] checkedObjects= fMethodsTree.getCheckedElements(); int methodCount= 0; for (int i = 0; i < checkedObjects.length; i++) { if (checkedObjects[i] instanceof IMethod)
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
methodCount++; } IMethod[] checkedMethods= new IMethod[methodCount]; int j= 0; for (int i = 0; i < checkedObjects.length; i++) { if (checkedObjects[i] instanceof IMethod) { checkedMethods[j]= (IMethod)checkedObjects[i]; j++; } } return checkedMethods; } private static class MethodsTreeContentProvider implements ITreeContentProvider { private Object[] fTypes; private IMethod[] fMethods; private final Object[] fEmpty= new Object[0]; public MethodsTreeContentProvider(Object[] types) { fTypes= types; Vector methods= new Vector(); for (int i = types.length-1; i > -1; i--) { Object object = types[i]; if (object instanceof IType) { IType type = (IType) object; try { IMethod[] currMethods= type.getMethods(); for_currMethods: for (int j = 0; j < currMethods.length; j++) { IMethod currMethod = currMethods[j]; int flags= currMethod.getFlags();
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
if (!Flags.isPrivate(flags)) { for (int k = 0; k < methods.size(); k++) { IMethod m= ((IMethod)methods.get(k)); if (m.getElementName().equals(currMethod.getElementName()) && m.getSignature().equals(currMethod.getSignature())) { methods.set(k,currMethod); continue for_currMethods; } } methods.add(currMethod); } } } catch (JavaModelException e) { System.err.println("MethodsTreeContentProvider: "+e); } } } fMethods= new IMethod[methods.size()]; methods.copyInto(fMethods); } /* * @see ITreeContentProvider#getChildren(Object) */ public Object[] getChildren(Object parentElement) { if (parentElement instanceof IType) { IType parentType= (IType)parentElement; ArrayList result= new ArrayList(fMethods.length); for (int i= 0; i < fMethods.length; i++) { if (fMethods[i].getDeclaringType().equals(parentType)) {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
result.add(fMethods[i]); } } return result.toArray(); } return fEmpty; } /* * @see ITreeContentProvider#getParent(Object) */ public Object getParent(Object element) { if (element instanceof IMethod) return ((IMethod)element).getDeclaringType(); return null; } /* * @see ITreeContentProvider#hasChildren(Object) */ public boolean hasChildren(Object element) { return getChildren(element).length > 0; } /* * @see IStructuredContentProvider#getElements(Object) */ public Object[] getElements(Object inputElement) { return fTypes; } /* * @see IContentProvider#dispose() */
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestCaseCreationWizardPage2.java
public void dispose() { } /* * @see IContentProvider#inputChanged(Viewer, Object, Object) */ public void inputChanged(Viewer viewer, Object oldInput, Object newInput) { } public IMethod[] getAllMethods() { return fMethods; } } public boolean getCreateTasksButtonSelection() { return fCreateTasksButton.getSelection(); } private void updateSelectedMethodsLabel() { Object[] checked= fMethodsTree.getCheckedElements(); int checkedMethodCount= 0; for (int i= 0; i < checked.length; i++) { if (checked[i] instanceof IMethod) checkedMethodCount++; } fSelectedMethodsLabel.setText(Messages.getFormattedString(((checkedMethodCount==1)?"NewTestClassWizPage2.selected_methods.label_one":"NewTestClassWizPage2.selected_methods.label_many"), new Integer(checkedMethodCount))); } public IMethod[] getAllMethods() { return ((MethodsTreeContentProvider)fMethodsTree.getContentProvider()).getAllMethods(); } }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizard.java
/* * (c) Copyright 2001 MyCorporation. * All Rights Reserved. */ package org.eclipse.jdt.junit.wizards; import java.lang.reflect.InvocationTargetException; import org.eclipse.core.resources.IResource; import org.eclipse.core.resources.IWorkspace; import org.eclipse.core.resources.ResourcesPlugin; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.NullProgressMonitor; import org.eclipse.jdt.core.IBuffer; import org.eclipse.jdt.core.ICompilationUnit; import org.eclipse.jdt.core.IMethod; import org.eclipse.jdt.core.IPackageFragment; import org.eclipse.jdt.core.ISourceRange; import org.eclipse.jdt.core.IType; import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility; import org.eclipse.jface.dialogs.MessageDialog; import org.eclipse.jface.dialogs.ProgressMonitorDialog; import org.eclipse.jface.operation.IRunnableWithProgress; import org.eclipse.ui.IEditorPart; /** * A wizard for creating TestSuites. */ public class NewTestSuiteCreationWizard extends JUnitWizard {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizard.java
private NewTestSuiteCreationWizardPage fPage; public NewTestSuiteCreationWizard() { super(); } /* * @see Wizard#createPages */ public void addPages() { super.addPages();
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizard.java
IWorkspace workspace= ResourcesPlugin.getWorkspace(); fPage= new NewTestSuiteCreationWizardPage(); addPage(fPage); fPage.init(getSelection()); } /* * @see Wizard#performFinish */ public boolean performFinish() { IPackageFragment pack= fPage.getPackageFragment(); String filename= fPage.getTypeName() + ".java"; ICompilationUnit cu= pack.getCompilationUnit(filename); if (cu.exists()) { IEditorPart cu_ep= EditorUtility.isOpenInEditor(cu); if (cu_ep != null && cu_ep.isDirty()) { boolean saveUnsavedChanges= MessageDialog.openQuestion(fPage.getShell(), Messages.getString("NewTestSuiteWiz.unsavedchangesDialog.title"), Messages.getFormattedString("NewTestSuiteWiz.unsavedchangesDialog.message", filename)); if (saveUnsavedChanges) { ProgressMonitorDialog progressDialog= new ProgressMonitorDialog(fPage.getShell()); try { progressDialog.run(false, false, getRunnableSave(cu_ep)); } catch (Exception e) { e.printStackTrace(); } } } IType suiteType= cu.getType(fPage.getTypeName()); IMethod suiteMethod= suiteType.getMethod("suite", new String[] {}); if (suiteMethod.exists()) { try {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizard.java
ISourceRange range= suiteMethod.getSourceRange(); IBuffer buf= cu.getBuffer(); String originalContent= buf.getText(range.getOffset(), range.getLength()); int start= originalContent.indexOf(NewTestSuiteCreationWizardPage.startMarker); if (start > -1) { int end= originalContent.indexOf(NewTestSuiteCreationWizardPage.endMarker, start); if (end < 0) { fPage.cannotUpdateSuiteError(); return false; } } else { fPage.cannotUpdateSuiteError(); return false; } } catch (JavaModelException e) { e.printStackTrace(); return false; } } } if (finishPage(fPage.getRunnable())) { if (!fPage.hasUpdatedExistingClass()) postCreatingType(); return true; } return false; } protected void postCreatingType() { IType newClass= fPage.getCreatedType();
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizard.java
ICompilationUnit cu= newClass.getCompilationUnit(); if (cu.isWorkingCopy()) { cu= (ICompilationUnit) cu.getOriginalElement(); } try { IResource resource= cu.getUnderlyingResource(); selectAndReveal(resource); openResource(resource); } catch (JavaModelException e) { System.err.println(getClass().getName() + ": " + e); } } public NewTestSuiteCreationWizardPage getPage() { return fPage; } public IRunnableWithProgress getRunnableSave(final IEditorPart cu_ep) { return new IRunnableWithProgress() { public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException { if (monitor == null) { monitor= new NullProgressMonitor(); } cu_ep.doSave(monitor); } }; } }
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizardPage.java
/* * (c) Copyright 2001 MyCorporation. * All Rights Reserved. */ package org.eclipse.jdt.junit.wizards; import java.lang.reflect.InvocationTargetException; import java.util.ArrayList; import java.util.List; import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.NullProgressMonitor; import org.eclipse.core.runtime.SubProgressMonitor; import org.eclipse.jdt.core.IBuffer; import org.eclipse.jdt.core.ICompilationUnit; import org.eclipse.jdt.core.IJavaElement; import org.eclipse.jdt.core.IMethod; import org.eclipse.jdt.core.IPackageFragment; import org.eclipse.jdt.core.IPackageFragmentRoot; import org.eclipse.jdt.core.ISourceRange; import org.eclipse.jdt.core.IType; import org.eclipse.jdt.core.JavaConventions;
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizardPage.java
import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.internal.corext.codemanipulation.IImportsStructure; import org.eclipse.jdt.internal.junit.util.*; import org.eclipse.jdt.internal.junit.util.TestSearchEngine; import org.eclipse.jdt.ui.JavaElementLabelProvider; import org.eclipse.jdt.ui.wizards.NewTypeWizardPage; import org.eclipse.jface.dialogs.MessageDialog; import org.eclipse.jface.operation.IRunnableWithProgress; import org.eclipse.jface.viewers.CheckStateChangedEvent; import org.eclipse.jface.viewers.CheckboxTableViewer; import org.eclipse.jface.viewers.ICheckStateListener; import org.eclipse.jface.viewers.IStructuredContentProvider; import org.eclipse.jface.viewers.IStructuredSelection; import org.eclipse.jface.viewers.Viewer; import org.eclipse.swt.SWT; import org.eclipse.swt.events.ModifyEvent; import org.eclipse.swt.events.ModifyListener; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Text; /** * Wizard page to select the test classes to include * in the test suite. */ public class NewTestSuiteCreationWizardPage extends NewTypeWizardPage {
11,866
Bug 11866 Wrong labels in Update Test Suite dialog
"Test Classes to be included" is written with TestClasses (missing space) The status line talks about methods being selected instead of types. The action name is written together (TestSuite) instead of Test Suite
resolved fixed
790bdf0
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-03-25T12:02:02Z
2002-03-20T16:00:00Z
org.eclipse.jdt.junit/src/org/eclipse/jdt/junit/wizards/NewTestSuiteCreationWizardPage.java
private final static String PAGE_NAME= "NewTestSuiteCreationWizardPage"; private final static String CLASSES_IN_SUITE= PAGE_NAME + ".classesinsuite"; private final static String SUITE_NAME= PAGE_NAME + ".suitename"; private final static String SELECTED_CLASSES_LABEL_TEXT_ONE= " class selected."; private final static String SELECTED_CLASSES_LABEL_TEXT_MANY= " classes selected."; private IPackageFragment fCurrentPackage; private CheckboxTableViewer fClassesInSuiteTable; private Button fSelectAllButton; private Button fDeselectAllButton; private Label fSelectedClassesLabel; private Label fSuiteNameLabel; private Text fSuiteNameText; private String fSuiteNameTextInitialValue; private boolean fUpdatedExistingClassButton; public static final String startMarker= "$JUnit-BEGIN$"; public static final String endMarker= "$JUnit-END$"; protected IStatus fClassesInSuiteStatus; protected IStatus fSuiteNameStatus;