Bug 96928 [1.5][model] Creating enum failed with exception in project with source level at 1.4
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
* interfaces, etc.
 * <p>
 * See {@link NewClassWizardPage} or {@link NewInterfaceWizardPage} for an
 * example usage of the <code>NewTypeWizardPage</code>.
 * </p>
 * 
 * @see org.eclipse.jdt.ui.wizards.NewClassWizardPage
 * @see org.eclipse.jdt.ui.wizards.NewInterfaceWizardPage
 * 
 * @since 2.0
 */
public abstract class NewTypeWizardPage extends NewContainerWizardPage {
	/**
	 * Class used in stub creation routines to add needed imports to a 
	 * compilation unit.
	 */
	public static class ImportsManager {
		private ImportsStructure fImportsStructure;
		private Set fAddedTypes;
		
		 ImportsManager(IImportsStructure importsStructure) {
			fImportsStructure= (ImportsStructure) importsStructure;
		}
		
		 ImportsManager(ICompilationUnit createdWorkingCopy) throws CoreException {
			this(createdWorkingCopy, new HashSet());
		}
		 ImportsManager(ICompilationUnit createdWorkingCopy, Set addedTypes) throws CoreException {
			IJavaProject javaProject= createdWorkingCopy.getJavaProject();
			String[] prefOrder= JavaPreferencesSettings.getImportOrderPreference(javaProject);