[280151] Remove deprecated and dead module mapping code
diff --git a/plugins/org.eclipse.jst.j2ee.navigator.ui/j2ee-navigator/org/eclipse/jst/j2ee/navigator/internal/EARContentProvider.java b/plugins/org.eclipse.jst.j2ee.navigator.ui/j2ee-navigator/org/eclipse/jst/j2ee/navigator/internal/EARContentProvider.java index db71f13..97396ac 100644 --- a/plugins/org.eclipse.jst.j2ee.navigator.ui/j2ee-navigator/org/eclipse/jst/j2ee/navigator/internal/EARContentProvider.java +++ b/plugins/org.eclipse.jst.j2ee.navigator.ui/j2ee-navigator/org/eclipse/jst/j2ee/navigator/internal/EARContentProvider.java
@@ -13,7 +13,6 @@ import org.eclipse.emf.ecore.EObject; import org.eclipse.jst.j2ee.application.ApplicationPackage; import org.eclipse.jst.j2ee.common.CommonPackage; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapPackage; /** * This class handles the EAR navigator content to the project explorer @@ -45,7 +44,7 @@ EObject eObject = (EObject)aParentElement; String emfPackage = eObject.eClass().getEPackage().getNsURI(); if (!emfPackage.equals(ApplicationPackage.eNS_URI)&& - !emfPackage.equals(CommonPackage.eNS_URI)&&!emfPackage.equals(ModulemapPackage.eNS_URI)) + !emfPackage.equals(CommonPackage.eNS_URI)) return new Object[]{}; } return super.getChildren(aParentElement);
diff --git a/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/provider/J2EEModulemapItemProviderAdapterFactory.java b/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/provider/J2EEModulemapItemProviderAdapterFactory.java deleted file mode 100644 index 0314662..0000000 --- a/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/provider/J2EEModulemapItemProviderAdapterFactory.java +++ /dev/null
@@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapAdapterFactory; - -public class J2EEModulemapItemProviderAdapterFactory extends ModulemapItemProviderAdapterFactory { - - /** - * Constructor for J2EEModulemapItemProviderAdapterFactory. - */ - public J2EEModulemapItemProviderAdapterFactory() { - super(); - } - - /** - * @see ModulemapAdapterFactory#createEARProjectMapAdapter() - */ - @Override - public Adapter createEARProjectMapAdapter() { - return new J2EEUtilityJavaProjectsItemProvider(this, false); - } - -}
diff --git a/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/provider/J2EEUtilityJavaProjectsItemProvider.java b/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/provider/J2EEUtilityJavaProjectsItemProvider.java deleted file mode 100644 index caf8e8e..0000000 --- a/plugins/org.eclipse.jst.j2ee.ui/j2ee_ui/org/eclipse/jst/j2ee/internal/provider/J2EEUtilityJavaProjectsItemProvider.java +++ /dev/null
@@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.jst.j2ee.internal.plugin.J2EEPlugin; -import org.eclipse.jst.j2ee.internal.plugin.J2EEUIMessages; - -public class J2EEUtilityJavaProjectsItemProvider extends EARProjectMapItemProvider { - - public final static String UTILITY_JAVA_PROJECTS = J2EEUIMessages.getResourceString("Utility_Java_Projects_UI_"); //$NON-NLS-1$ - - /** - * Constructor for UtilityJARsItemProvider. - * - * @param adapterFactory - */ - public J2EEUtilityJavaProjectsItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * Constructor for UtilityJARsItemProvider. - * - * @param adapterFactory - * @param includeModules - */ - public J2EEUtilityJavaProjectsItemProvider(AdapterFactory adapterFactory, boolean includeModules) { - super(adapterFactory, includeModules); - } - - /** - * @see ItemProviderAdapter#getImage(Object) - */ - @Override - public Object getImage(Object object) { - return J2EEPlugin.getPlugin().getImage("folder"); //$NON-NLS-1$ - } - - /** - * @see ItemProviderAdapter#getText(Object) - */ - @Override - public String getText(Object object) { - return UTILITY_JAVA_PROJECTS; - } - -}
diff --git a/plugins/org.eclipse.jst.j2ee/META-INF/MANIFEST.MF b/plugins/org.eclipse.jst.j2ee/META-INF/MANIFEST.MF index 3588b55..37855ce 100644 --- a/plugins/org.eclipse.jst.j2ee/META-INF/MANIFEST.MF +++ b/plugins/org.eclipse.jst.j2ee/META-INF/MANIFEST.MF
@@ -31,7 +31,6 @@ org.eclipse.jst.j2ee.internal.deploy;x-internal:=true, org.eclipse.jst.j2ee.internal.deployables;x-internal:=true, org.eclipse.jst.j2ee.internal.earcreation;x-internal:=true, - org.eclipse.jst.j2ee.internal.earcreation.modulemap;x-internal:=true, org.eclipse.jst.j2ee.internal.modulecore.util;x-internal:=true, org.eclipse.jst.j2ee.internal.moduleextension;x-internal:=true, org.eclipse.jst.j2ee.internal.plugin;x-internal:=true,
diff --git a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/EARProjectMapItemProvider.java b/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/EARProjectMapItemProvider.java deleted file mode 100644 index 09ec28e..0000000 --- a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/EARProjectMapItemProvider.java +++ /dev/null
@@ -1,175 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.edit.command.AddCommand; -import org.eclipse.emf.edit.command.RemoveCommand; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.jst.j2ee.internal.application.provider.ApplicationProvidersResourceHandler; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.EARProjectMap; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapPackage; -import org.eclipse.jst.j2ee.internal.plugin.J2EEPlugin; - - - -/** - * This is the item provider adpater for a - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.EARProjectMap} - * object. - */ -public class EARProjectMapItemProvider extends ModulemapItemProviderAdapter implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** Added to generated code */ - protected boolean includeModules = false; - - /** - * This constructs an instance from a factory and a notifier. - */ - public EARProjectMapItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - public EARProjectMapItemProvider(AdapterFactory adapterFactory, boolean includeModules) { - this(adapterFactory); - this.includeModules = includeModules; - } - - /** - * This returns the property descriptors for the adapted class. - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - } - return itemPropertyDescriptors; - } - - /** - * This specifies how to implement {@link #getChildren}and {@link AddCommand}and - * {@link RemoveCommand}support in {@link #createCommand}. - */ - @Override - public Collection getChildrenReferences(Object object) { - if (childrenReferences == null) { - super.getChildrenReferences(object); - if (includeModules) - childrenReferences.add(ModulemapPackage.eINSTANCE.getEARProjectMap_Mappings()); - childrenReferences.add(ModulemapPackage.eINSTANCE.getEARProjectMap_UtilityJARMappings()); - } - return childrenReferences; - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EReference getChildReference(Object object, Object child) { - // TODO: Check the type of the specified child object and return the proper feature to use - // for - // adding (see {@link AddCommand}) it as a child. - - return super.getChildReference(object, child); - } - - - /** - * This returns the parent of the EARProjectMap. - */ - @Override - public Object getParent(Object object) { - return ((EObject) object).eContainer(); - } - - /** - * This returns EARProjectMap.gif. - */ - @Override - public Object getImage(Object object) { - return J2EEPlugin.getPlugin().getImage("EARProjectMap"); //$NON-NLS-1$ - } - - @Override - public String getText(Object object) { - return ApplicationProvidersResourceHandler.getString("EARProjectMap_UI_"); //$NON-NLS-1$ - } - - /** - * This handles notification by calling {@link #fireNotifyChanged fireNotifyChanged}. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - switch (notification.getFeatureID(EARProjectMap.class)) { - case ModulemapPackage.EAR_PROJECT_MAP__MAPPINGS : - case ModulemapPackage.EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS : { - fireNotifyChanged(notification); - return; - } - } - super.notifyChanged(notification); - } - - /** - * This handles notification by calling {@link #fireNotifyChanged fireNotifyChanged}. - */ - /* - * public void notifyChanged(Notifier notifier, int eventType, EObject feature, Object oldValue, - * Object newValue, int index) { ModulemapPackage pkg = ModulemapPackage.eINSTANCE;; if - * (!includeModules && feature == pkg.getEARProjectMap_Mappings()) return; - * - * if (feature == pkg.getEARProjectMap_Mappings() || feature == - * pkg.getEARProjectMap_UtilityJARMappings()) { fireNotifyChanged(notifier, eventType, feature, - * oldValue, newValue, index); return; } super.notifyChanged(notifier, eventType, feature, - * oldValue, newValue, index); } - */ - - /** - * This adds to the collection of {@linkcom.ibm.etools.emf.edit.command.CommandParameter}s - * describing all of the children that can be created under this object. - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - - if (includeModules) - newChildDescriptors.add(createChildParameter(modulemapPackage.getEARProjectMap_Mappings(), modulemapPackage.getModuleMapping())); - newChildDescriptors.add(createChildParameter(modulemapPackage.getEARProjectMap_UtilityJARMappings(), modulemapPackage.getUtilityJARMapping())); - } - - /** - * Return the resource locator for this item provider's resources. <!-- begin-user-doc --> <!-- - * end-user-doc --> - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ApplicationProvidersResourceHandler.RESOURCE_LOCATOR; - } -}
diff --git a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModuleMappingItemProvider.java b/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModuleMappingItemProvider.java deleted file mode 100644 index a93b026..0000000 --- a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModuleMappingItemProvider.java +++ /dev/null
@@ -1,172 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.jst.j2ee.internal.application.provider.ApplicationProvidersResourceHandler; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModuleMapping; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapPackage; -import org.eclipse.jst.j2ee.internal.plugin.J2EEPlugin; - - - -/** - * This is the item provider adpater for a - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.ModuleMapping} - * object. - */ -public class ModuleMappingItemProvider extends ModulemapItemProviderAdapter implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - */ - public ModuleMappingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - ModulemapPackage pkg = ModulemapPackage.eINSTANCE; - - // This is for the projectName feature. - // - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), ApplicationProvidersResourceHandler.getString("Project_Name_1"), //$NON-NLS-1$ - ApplicationProvidersResourceHandler.getString("The_project_name_property_of_the_module_mapping_UI_"), //$NON-NLS-1$ - pkg.getModuleMapping_ProjectName(), true, ItemPropertyDescriptor.TEXT_VALUE_IMAGE)); - - // This is for the module feature. - // - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), ApplicationProvidersResourceHandler.getString("Module_UI_"), //$NON-NLS-1$ - ApplicationProvidersResourceHandler.getString("The_module_of_the_module_mapping_UI_"), //$NON-NLS-1$ - pkg.getModuleMapping_Module(), false)); - - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Project Name feature. <!-- begin-user-doc --> <!-- - * end-user-doc --> - * - * @generated - */ - protected void addProjectNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getString("_UI_ModuleMapping_projectName_feature"), //$NON-NLS-1$ - getString("_UI_PropertyDescriptor_description", "_UI_ModuleMapping_projectName_feature", "_UI_ModuleMapping_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ - ModulemapPackage.eINSTANCE.getModuleMapping_ProjectName(), true, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE)); - } - - /** - * This adds a property descriptor for the Module feature. <!-- begin-user-doc --> <!-- - * end-user-doc --> - * - * @generated - */ - protected void addModulePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getString("_UI_ModuleMapping_module_feature"), //$NON-NLS-1$ - getString("_UI_PropertyDescriptor_description", "_UI_ModuleMapping_module_feature", "_UI_ModuleMapping_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ - ModulemapPackage.eINSTANCE.getModuleMapping_Module(), true)); - } - - - /** - * This returns the parent of the ModuleMapping. - */ - @Override - public Object getParent(Object object) { - return ((EObject) object).eContainer(); - } - - /** - * This returns ModuleMapping.gif. - */ - @Override - public Object getImage(Object object) { - return J2EEPlugin.getPlugin().getImage("ModuleMapping"); //$NON-NLS-1$ - } - - @Override - public String getText(Object object) { - ModuleMapping moduleMapping = ((ModuleMapping) object); - return ApplicationProvidersResourceHandler.getString("ModuleMapping_UI_") + moduleMapping.getProjectName(); //$NON-NLS-1$ - } - - /** - * This handles notification by calling {@link #fireNotifyChanged fireNotifyChanged}. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - switch (notification.getFeatureID(ModuleMapping.class)) { - case ModulemapPackage.MODULE_MAPPING__PROJECT_NAME : - case ModulemapPackage.MODULE_MAPPING__MODULE : { - fireNotifyChanged(notification); - return; - } - } - super.notifyChanged(notification); - } - - /** - * This adds to the collection of {@link org.eclipse.emf.edit.command.CommandParameter}s - * describing all of the children that can be created under this object. <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. <!-- begin-user-doc --> <!-- - * end-user-doc --> - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ApplicationProvidersResourceHandler.RESOURCE_LOCATOR; - } - /** - * This handles notification by calling {@link #fireNotifyChanged fireNotifyChanged}. - */ - /* - * public void notifyChanged(Notifier notifier, int eventType, EObject feature, Object oldValue, - * Object newValue, int index) { ModulemapPackage pkg = ModulemapPackage.eINSTANCE;; if ( - * feature == pkg.getModuleMapping_ProjectName() || feature == pkg.getModuleMapping_Module() ) { - * fireNotifyChanged(notifier, eventType, feature, oldValue, newValue, index); return; } - * super.notifyChanged(notifier, eventType, feature, oldValue, newValue, index); } - */ -}
diff --git a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapEditPlugin.java b/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapEditPlugin.java deleted file mode 100644 index f2f41f5..0000000 --- a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapEditPlugin.java +++ /dev/null
@@ -1,126 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2004 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - - -import java.net.MalformedURLException; -import java.net.URL; -import java.text.MessageFormat; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IPluginDescriptor; -import org.eclipse.core.runtime.Plugin; -import org.eclipse.jst.j2ee.internal.application.provider.ApplicationProvidersResourceHandler; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapFactory; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapPackage; - - - -/** - * @deprecated Leaving this in for now, to minimize breakage to all the providers; should delete - * when we regen all providers for mof5 - * - * This is the central singleton for the modulemap plugin. - */ -public class ModulemapEditPlugin extends Plugin { - /** - * Keep track of the singleton. - */ - protected static ModulemapEditPlugin plugin; - - /** - * Keep track of the modulemap package. - */ - protected ModulemapPackage modulemapPackage; - - /** - * Create the instance. - */ - public ModulemapEditPlugin(IPluginDescriptor descriptor) { - super(descriptor); - - // Remember the static instance. - // - plugin = this; - } - - /** - * Get the one modulemap package. - */ - public ModulemapPackage getModulemapPackage() { - return modulemapPackage; - } - - /** - * Get the one modulemap factory. - */ - public ModulemapFactory getModulemapFactory() { - return (ModulemapFactory) modulemapPackage.getEFactoryInstance(); - } - - /** - * Do initialization stuff here. - */ - @Override - public void startup() throws CoreException { - super.startup(); - modulemapPackage = org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapFactoryImpl.getPackage(); - } - - /** - * Get the singleton instance. - */ - public static ModulemapEditPlugin getPlugin() { - return plugin; - } - - /** - * Get a .gif from the icons folder. - */ - public Object getImage(String key) { - try { - return new URL(getDescriptor().getInstallURL(), "icons/" + key + ".gif"); //$NON-NLS-1$ //$NON-NLS-2$ - } catch (MalformedURLException exception) { - System.out.println(ApplicationProvidersResourceHandler.getString("Failed_to_load_image_for_ERROR_") + key + "'"); //$NON-NLS-1$ //$NON-NLS-2$ - exception.printStackTrace(); - } - - return null; - } - - /** - * Get a translated string from the resource bundle. - */ - public String getString(String key) { - return getDescriptor().getResourceBundle().getString(key); - } - - /** - * Get a translated string from the resource bundle, with an object substitution. - */ - public String getString(String key, Object s1) { - return MessageFormat.format(getString(key), new Object[]{s1}); - } - - /** - * Get a translated string from the resource bundle, with two object substitutions. - */ - public String getString(String key, Object s1, Object s2) { - return MessageFormat.format(getString(key), new Object[]{s1, s2}); - } - - /** - * Get a translated string from the resource bundle, with three object substitutions. - */ - public String getString(String key, Object s1, Object s2, Object s3) { - return MessageFormat.format(getString(key), new Object[]{s1, s2, s3}); - } -} \ No newline at end of file
diff --git a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapItemProviderAdapter.java b/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapItemProviderAdapter.java deleted file mode 100644 index 784e698..0000000 --- a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapItemProviderAdapter.java +++ /dev/null
@@ -1,141 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - - - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.command.Command; -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.edit.command.CommandParameter; -import org.eclipse.emf.edit.domain.EditingDomain; -import org.eclipse.emf.edit.provider.ItemProviderAdapter; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapFactory; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapPackage; -import org.eclipse.jst.j2ee.internal.plugin.J2EEPlugin; - - - -/** - * This extended item provider supports the following commands: - * <ul> - * <li>{@link CreateChildCommand} - * </ul> - * <p> - * The commands are implemented uniformly on all our item adapters using this common base class. - */ -public class ModulemapItemProviderAdapter extends ItemProviderAdapter { - /** - * This is the package for the modulemap model. - */ - protected static final ModulemapPackage modulemapPackage = (ModulemapPackage) EPackage.Registry.INSTANCE.getEPackage(ModulemapPackage.eNS_URI); - /** - * This is the factory for the modulemap model. - */ - protected static final ModulemapFactory modulemapFactory = modulemapPackage.getModulemapFactory(); - - /** - * This creates an instance from an adapter factory and a domain notifier. - */ - protected ModulemapItemProviderAdapter(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This creates the supported commands. - */ - @Override - public Command createCommand(Object object, EditingDomain editingDomain, Class commandClass, CommandParameter commandParameter) { - return super.createCommand(object, editingDomain, commandClass, commandParameter); - } - - /** - * This is a convenience method for creating <code>CommandParameter</code> s for a given - * parent feature and child type (MOF meta-object). - */ - protected CommandParameter createChildParameter(EReference feature, EObject childType) { - return new CommandParameter(null, feature, modulemapFactory.create(childType.eClass())); - } - - /** - * This returns the default owner object for {@link CreateChildCommand}. - */ - public Object getCreateChildOwner(Object parent) { - return parent; - } - - /** - * This returns the default result collection for {@link CreateChildCommand}. - */ - @Override - public Collection getCreateChildResult(Object child) { - Collection result = new ArrayList(1); - result.add(child); - return result; - } - - /** - * This returns the default label for {@link CreateChildCommand}. - */ - public String getCreateChildText(Object parent, Object feature, Object child) { - return J2EEPlugin.getPlugin().getString("_UI_CreateChild_text"); //$NON-NLS-1$ - } - - /** - * This returns the default description for {@link CreateChildCommand}. - */ - public String getCreateChildDescription(Object parent, Object feature, Object child) { - return J2EEPlugin.getPlugin().getString("_UI_CreateChild_description"); //$NON-NLS-1$ - } - - /** - * This returns the default help text for {@link CreateChildCommand}. - */ - public String getCreateChildToolTipText(Object parent, Object feature, Object child) { - return J2EEPlugin.getPlugin().getString("_UI_CreateChild_tooltip"); //$NON-NLS-1$ - } - - /** - * This returns the default image for {@link CreateChildCommand}. - */ - public Object getCreateChildImage(Object parent, Object feature, Object child) { - Object image = null; - - if (parent instanceof EObject && child instanceof EObject) { - String name = ((EObject) parent).eClass().getName() + "Create" + ((EObject) child).eClass().getName(); //$NON-NLS-1$ - image = J2EEPlugin.getPlugin().getImage(name); - } - return image; - } - - /** - * This looks up the name of the type of the specified object. - */ - @Override - protected String getTypeText(Object object) { - String typeKey = object instanceof EObject ? ((EObject) object).eClass().getName() : "Unknown"; //$NON-NLS-1$ - return J2EEPlugin.getPlugin().getString("_UI_" + typeKey + "_type"); //$NON-NLS-1$ //$NON-NLS-2$ - } - - /** - * This looks up the name of the specified feature. - */ - @Override - protected String getFeatureText(Object feature) { - String featureKey = feature instanceof EReference ? ((EReference) feature).getName() : "Unknown"; //$NON-NLS-1$ - return J2EEPlugin.getPlugin().getString("_UI_" + featureKey + "_feature"); //$NON-NLS-1$ //$NON-NLS-2$ - } -}
diff --git a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapItemProviderAdapterFactory.java b/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapItemProviderAdapterFactory.java deleted file mode 100644 index 943fa93..0000000 --- a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/ModulemapItemProviderAdapterFactory.java +++ /dev/null
@@ -1,221 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - - - -import java.util.ArrayList; -import java.util.Collection; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.provider.ChangeNotifier; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.ComposedAdapterFactory; -import org.eclipse.emf.edit.provider.IChangeNotifier; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.INotifyChangedListener; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITableItemLabelProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapAdapterFactory; - - - -/** - * This is the factory that is used to provide the interfaces needed to support - * {@link org.eclipse.jface.viewers.Viewer}s. The adapters generated by this factory convert EMF - * adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. The adapters - * also support property sheets, see {@link org.eclipse.ui.views.properties}. Note that most of the - * adapters are shared among multiple instances. - */ -public class ModulemapItemProviderAdapterFactory extends ModulemapAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier { - /** - * This keeps track of the root adapter factory that delegates to this adapter factory. - */ - protected ComposedAdapterFactory parentAdapterFactory; - - /** - * This is used to implement {@link #com.ibm.etools.emf.edit.provider.IChangeNotifier}. - */ - protected IChangeNotifier changeNotifier = new ChangeNotifier(); - - /** - * This keeps track of all the supported types checked by - * {@link #isFactoryForType isFactoryForType}. - */ - protected Collection supportedTypes = new ArrayList(); - - /** - * This constructs an instance. - */ - public ModulemapItemProviderAdapterFactory() { - supportedTypes.add(IStructuredItemContentProvider.class); - supportedTypes.add(ITreeItemContentProvider.class); - supportedTypes.add(IItemPropertySource.class); - supportedTypes.add(IEditingDomainItemProvider.class); - supportedTypes.add(IItemLabelProvider.class); - supportedTypes.add(ITableItemLabelProvider.class); - } - - /** - * This keeps track of the one adapter used for all - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.ModuleMapping} - * instances. - */ - protected ModuleMappingItemProvider moduleMappingItemProvider; - - /** - * This creates an adapter for a - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.ModuleMapping}. - */ - @Override - public Adapter createModuleMappingAdapter() { - if (moduleMappingItemProvider == null) { - moduleMappingItemProvider = new ModuleMappingItemProvider(this); - } - - return moduleMappingItemProvider; - } - - /** - * This keeps track of the one adapter used for all - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.EARProjectMap} - * instances. - */ - protected EARProjectMapItemProvider earProjectMapItemProvider; - - /** - * This creates an adapter for a - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.EARProjectMap}. - */ - @Override - public Adapter createEARProjectMapAdapter() { - if (earProjectMapItemProvider == null) { - earProjectMapItemProvider = new EARProjectMapItemProvider(this); - } - - return earProjectMapItemProvider; - } - - /** - * This keeps track of the one adapter used for all - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.UtilityJARMapping} - * instances. - */ - protected UtilityJARMappingItemProvider utilityJARMappingItemProvider; - - /** - * This creates an adapter for a - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.UtilityJARMapping}. - */ - @Override - public Adapter createUtilityJARMappingAdapter() { - if (utilityJARMappingItemProvider == null) { - utilityJARMappingItemProvider = new UtilityJARMappingItemProvider(this); - } - - return utilityJARMappingItemProvider; - } - - /** - * This returns the root adapter factory that contains this factory. - */ - public ComposeableAdapterFactory getRootAdapterFactory() { - return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); - } - - /** - * This sets the composed adapter factory that contains this factory. - */ - public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { - this.parentAdapterFactory = parentAdapterFactory; - } - - @Override - public boolean isFactoryForType(Object type) { - return super.isFactoryForType(type) || supportedTypes.contains(type); - } - - /** - * This implementation substitutes the factory itself as the key for the adapter. - */ - @Override - public Adapter adapt(Notifier notifier, Object type) { - return super.adapt(notifier, this); - } - - @Override - public Object adapt(Object object, Object type) { - // This is a kludge to deal with enumerators, which crash the doSwitch. - // - if (object instanceof EObject && ((EObject) object).eClass() == null) { - return null; - } - - if (isFactoryForType(type)) { - Object adapter = super.adapt(object, type); - if (!(type instanceof Class) || (((Class) type).isInstance(adapter))) { - return adapter; - } - } - - return null; - } - - /** - * This adds a listener. <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - public void addListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.addListener(notifyChangedListener); - } - - /** - * This removes a listener. - * - * @generated - */ - public void removeListener(INotifyChangedListener notifyChangedListener) { - changeNotifier.removeListener(notifyChangedListener); - } - - /** - * This delegates to {@link #changeNotifier}and to {@link #parentAdapterFactory}. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - public void fireNotifyChanged(Notification notification) { - changeNotifier.fireNotifyChanged(notification); - - if (parentAdapterFactory != null) { - parentAdapterFactory.fireNotifyChanged(notification); - } - } - - /** - * This delegates to {@link #changeNotifier}and to {@link #parentAdapterFactory}. - */ - /* - * public void fireNotifyChanged(Object object, int eventType, Object feature, Object oldValue, - * Object newValue, int index) { changeNotifier.fireNotifyChanged(object, eventType, feature, - * oldValue, newValue, index); - * - * if (parentAdapterFactory != null) { parentAdapterFactory.fireNotifyChanged(object, eventType, - * feature, oldValue, newValue, index); } } - */ -}
diff --git a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/UtilityJARMappingItemProvider.java b/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/UtilityJARMappingItemProvider.java deleted file mode 100644 index f419559..0000000 --- a/plugins/org.eclipse.jst.j2ee/applicationedit/org/eclipse/jst/j2ee/internal/provider/UtilityJARMappingItemProvider.java +++ /dev/null
@@ -1,197 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.provider; - - - -import java.util.Collection; -import java.util.List; - -import org.eclipse.emf.common.notify.AdapterFactory; -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.util.ResourceLocator; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; -import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; -import org.eclipse.emf.edit.provider.IItemLabelProvider; -import org.eclipse.emf.edit.provider.IItemPropertySource; -import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; -import org.eclipse.emf.edit.provider.ITreeItemContentProvider; -import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; -import org.eclipse.jst.j2ee.internal.application.provider.ApplicationProvidersResourceHandler; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapPackage; -import org.eclipse.jst.j2ee.internal.earcreation.modulemap.UtilityJARMapping; -import org.eclipse.jst.j2ee.internal.plugin.J2EEPlugin; - - - -/** - * This is the item provider adpater for a - * {@link org.eclipse.jst.j2ee.internal.internal.internal.earcreation.modulemap.UtilityJARMapping} - * object. - */ -public class UtilityJARMappingItemProvider extends ModulemapItemProviderAdapter implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource { - /** - * This constructs an instance from a factory and a notifier. - */ - public UtilityJARMappingItemProvider(AdapterFactory adapterFactory) { - super(adapterFactory); - } - - /** - * This returns the property descriptors for the adapted class. - */ - @Override - public List getPropertyDescriptors(Object object) { - if (itemPropertyDescriptors == null) { - super.getPropertyDescriptors(object); - - ModulemapPackage pkg = ModulemapPackage.eINSTANCE; - - // This is for the projectName feature. - // - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), ApplicationProvidersResourceHandler.getString("Project_Name_UI_"), //$NON-NLS-1$ - ApplicationProvidersResourceHandler.getString("The_project_name_property_of_the_utility_jar_mapping_UI_"), //$NON-NLS-1$ - pkg.getUtilityJARMapping_ProjectName(), false, ItemPropertyDescriptor.TEXT_VALUE_IMAGE)); - - // This is for the uri feature. - // - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), ApplicationProvidersResourceHandler.getString("Uri_UI_"), //$NON-NLS-1$ - ApplicationProvidersResourceHandler.getString("The_uri_property_of_the_utility_jar_mapping_UI_"), //$NON-NLS-1$ - pkg.getUtilityJARMapping_Uri(), true, ItemPropertyDescriptor.TEXT_VALUE_IMAGE)); - - } - return itemPropertyDescriptors; - } - - /** - * This adds a property descriptor for the Project Name feature. <!-- begin-user-doc --> <!-- - * end-user-doc --> - * - * @generated - */ - protected void addProjectNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getString("_UI_UtilityJARMapping_projectName_feature"), //$NON-NLS-1$ - getString("_UI_PropertyDescriptor_description", "_UI_UtilityJARMapping_projectName_feature", "_UI_UtilityJARMapping_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ - ModulemapPackage.eINSTANCE.getUtilityJARMapping_ProjectName(), true, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE)); - } - - /** - * This adds a property descriptor for the Uri feature. <!-- begin-user-doc --> <!-- - * end-user-doc --> - * - * @generated - */ - protected void addUriPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(new ItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getString("_UI_UtilityJARMapping_uri_feature"), //$NON-NLS-1$ - getString("_UI_PropertyDescriptor_description", "_UI_UtilityJARMapping_uri_feature", "_UI_UtilityJARMapping_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ - ModulemapPackage.eINSTANCE.getUtilityJARMapping_Uri(), true, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE)); - } - - - /** - * This returns the parent of the UtilityJARMapping. - */ - @Override - public Object getParent(Object object) { - return ((EObject) object).eContainer(); - } - - /** - * This returns UtilityJARMapping.gif. - */ - @Override - public Object getImage(Object object) { - return J2EEPlugin.getPlugin().getImage("icons/full/obj16/prjutiljar_obj"); //$NON-NLS-1$ - } - - // /** - // * @param object - // * @return - // */ - // private boolean isEJBClientJAR(Object object) { - // UtilityJARMapping map = (UtilityJARMapping) object; - // IProject project = ProjectUtilities.getProject(map); - // if (project == null) - // return false; - // - // EARNatureRuntime runtime = EARNatureRuntime.getRuntime(project); - // if (runtime == null) - // return false; - // - // EAREditModel model = null; - // try { - // model = runtime.getEarEditModelForRead(this); - // return model.isEjbClientJarMapping(map); - // } finally { - // if (model != null) - // model.releaseAccess(this); - // } - // } - - @Override - public String getText(Object object) { - UtilityJARMapping map = ((UtilityJARMapping) object); - return map == null ? "<??>" : map.getUri(); //$NON-NLS-1$ - } - - /** - * This handles notification by calling {@link #fireNotifyChanged fireNotifyChanged}. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public void notifyChanged(Notification notification) { - switch (notification.getFeatureID(UtilityJARMapping.class)) { - case ModulemapPackage.UTILITY_JAR_MAPPING__PROJECT_NAME : - case ModulemapPackage.UTILITY_JAR_MAPPING__URI : { - fireNotifyChanged(notification); - return; - } - } - super.notifyChanged(notification); - } - - /** - * This adds to the collection of {@link org.eclipse.emf.edit.command.CommandParameter}s - * describing all of the children that can be created under this object. <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - @Override - protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { - super.collectNewChildDescriptors(newChildDescriptors, object); - } - - /** - * Return the resource locator for this item provider's resources. <!-- begin-user-doc --> <!-- - * end-user-doc --> - * - * @generated - */ - @Override - public ResourceLocator getResourceLocator() { - return ApplicationProvidersResourceHandler.RESOURCE_LOCATOR; - } - /** - * This handles notification by calling {@link #fireNotifyChanged fireNotifyChanged}. - */ - /* - * public void notifyChanged(Notifier notifier, int eventType, EObject feature, Object oldValue, - * Object newValue, int index) { ModulemapPackage pkg = ModulemapPackage.eINSTANCE;; if ( - * feature == pkg.getUtilityJARMapping_ProjectName() || feature == - * pkg.getUtilityJARMapping_Uri() ) { fireNotifyChanged(notifier, eventType, feature, oldValue, - * newValue, index); return; } super.notifyChanged(notifier, eventType, feature, oldValue, - * newValue, index); } - */ -}
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/EARProjectMap.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/EARProjectMap.java deleted file mode 100644 index 49d57de..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/EARProjectMap.java +++ /dev/null
@@ -1,40 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; - - -/** - * @lastgen interface EARProjectMap extends EObject {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public interface EARProjectMap extends EObject { - /** - * @generated This field/method will be replaced during code generation - * @return The list of Mappings references - */ - EList getMappings(); - - /** - * @generated This field/method will be replaced during code generation - * @return The list of UtilityJARMappings references - */ - EList getUtilityJARMappings(); - -} //EARProjectMap
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/EARProjectMapImpl.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/EARProjectMapImpl.java deleted file mode 100644 index 7bbf17d..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/EARProjectMapImpl.java +++ /dev/null
@@ -1,177 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.NotificationChain; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.InternalEObject; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.InternalEList; - - - -/** - * @lastgen class EARProjectMapImpl extends EObjectImpl implements EARProjectMap, EObject {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public class EARProjectMapImpl extends EObjectImpl implements EARProjectMap { - /** - * @generated This field/method will be replaced during code generation. - */ - /** - * @generated This field/method will be replaced during code generation. - */ - protected EList mappings = null; - /** - * @generated This field/method will be replaced during code generation. - */ - protected EList utilityJARMappings = null; - - - - /** - * @generated This field/method will be replaced during code generation. - */ - protected EARProjectMapImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModulemapPackage.eINSTANCE.getEARProjectMap(); - } - - /** - * @generated This field/method will be replaced during code generation - */ - public EList getMappings() { - if (mappings == null) { - mappings = new EObjectContainmentEList(ModuleMapping.class, this, ModulemapPackage.EAR_PROJECT_MAP__MAPPINGS); - } - return mappings; - } - - /** - * @generated This field/method will be replaced during code generation - */ - public EList getUtilityJARMappings() { - if (utilityJARMappings == null) { - utilityJARMappings = new EObjectContainmentEList(UtilityJARMapping.class, this, ModulemapPackage.EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS); - } - return utilityJARMappings; - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, Class baseClass, NotificationChain msgs) { - if (featureID >= 0) { - switch (baseClass == null ? featureID : eDerivedStructuralFeatureID(featureID, baseClass)) { - case ModulemapPackage.EAR_PROJECT_MAP__MAPPINGS : - return ((InternalEList) getMappings()).basicRemove(otherEnd, msgs); - case ModulemapPackage.EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS : - return ((InternalEList) getUtilityJARMappings()).basicRemove(otherEnd, msgs); - default : - return eDynamicInverseRemove(otherEnd, featureID, baseClass, msgs); - } - } - return eBasicSetContainer(null, featureID, msgs); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eGet(EStructuralFeature eFeature, boolean resolve) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.EAR_PROJECT_MAP__MAPPINGS : - return getMappings(); - case ModulemapPackage.EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS : - return getUtilityJARMappings(); - } - return eDynamicGet(eFeature, resolve); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eSet(EStructuralFeature eFeature, Object newValue) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.EAR_PROJECT_MAP__MAPPINGS : - getMappings().clear(); - getMappings().addAll((Collection) newValue); - return; - case ModulemapPackage.EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS : - getUtilityJARMappings().clear(); - getUtilityJARMappings().addAll((Collection) newValue); - return; - } - eDynamicSet(eFeature, newValue); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public void eUnset(EStructuralFeature eFeature) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.EAR_PROJECT_MAP__MAPPINGS : - getMappings().clear(); - return; - case ModulemapPackage.EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS : - getUtilityJARMappings().clear(); - return; - } - eDynamicUnset(eFeature); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public boolean eIsSet(EStructuralFeature eFeature) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.EAR_PROJECT_MAP__MAPPINGS : - return mappings != null && !mappings.isEmpty(); - case ModulemapPackage.EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS : - return utilityJARMappings != null && !utilityJARMappings.isEmpty(); - } - return eDynamicIsSet(eFeature); - } - -} //EARProjectMapImpl
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModuleMapping.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModuleMapping.java deleted file mode 100644 index cee99ee..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModuleMapping.java +++ /dev/null
@@ -1,55 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.jst.j2ee.application.Module; - - - -/** - * @lastgen interface ModuleMapping extends EObject {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - * </p> - */ -public interface ModuleMapping extends EObject { - /** - * @generated This field/method will be replaced during code generation - * @return The value of the ProjectName attribute - */ - String getProjectName(); - - /** - * @generated This field/method will be replaced during code generation - * @param value - * The new value of the ProjectName attribute - */ - void setProjectName(String value); - - /** - * @generated This field/method will be replaced during code generation - * @return The Module reference - */ - Module getModule(); - - /** - * @generated This field/method will be replaced during code generation - * @param l - * The new value of the Module reference - */ - void setModule(Module value); - -} //ModuleMapping
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModuleMappingImpl.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModuleMappingImpl.java deleted file mode 100644 index d09807c..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModuleMappingImpl.java +++ /dev/null
@@ -1,200 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.jst.j2ee.application.Module; -import org.eclipse.jst.j2ee.internal.earcreation.EARCreationResourceHandler; - - -/** - * @lastgen class ModuleMappingImpl extends EObjectImpl implements ModuleMapping, EObject {} - * * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public class ModuleMappingImpl extends EObjectImpl implements ModuleMapping { - /** - * The default value of the '{@link #getProjectName() <em>Project Name</em>}' attribute. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected static final String PROJECT_NAME_EDEFAULT = null; - - /** - * @generated This field/method will be replaced during code generation. - */ - /** - * @generated This field/method will be replaced during code generation. - */ - protected String projectName = PROJECT_NAME_EDEFAULT; - /** - * @generated This field/method will be replaced during code generation. - */ - protected Module module = null; - - /** - * @generated This field/method will be replaced during code generation. - */ - protected ModuleMappingImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModulemapPackage.eINSTANCE.getModuleMapping(); - } - - /** - * @generated This field/method will be replaced during code generation - */ - public String getProjectName() { - return projectName; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public void setProjectName(String newProjectName) { - String oldProjectName = projectName; - projectName = newProjectName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModulemapPackage.MODULE_MAPPING__PROJECT_NAME, oldProjectName, projectName)); - } - - /** - * @generated This field/method will be replaced during code generation - */ - public Module getModule() { - if (module != null && module.eIsProxy()) { - Module oldModule = module; - module = (Module) EcoreUtil.resolve(module, this); - if (module != oldModule) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, ModulemapPackage.MODULE_MAPPING__MODULE, oldModule, module)); - } - } - return module; - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - public Module basicGetModule() { - return module; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public void setModule(Module newModule) { - Module oldModule = module; - module = newModule; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModulemapPackage.MODULE_MAPPING__MODULE, oldModule, module)); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eGet(EStructuralFeature eFeature, boolean resolve) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.MODULE_MAPPING__PROJECT_NAME : - return getProjectName(); - case ModulemapPackage.MODULE_MAPPING__MODULE : - if (resolve) - return getModule(); - return basicGetModule(); - } - return eDynamicGet(eFeature, resolve); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public boolean eIsSet(EStructuralFeature eFeature) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.MODULE_MAPPING__PROJECT_NAME : - return PROJECT_NAME_EDEFAULT == null ? projectName != null : !PROJECT_NAME_EDEFAULT.equals(projectName); - case ModulemapPackage.MODULE_MAPPING__MODULE : - return module != null; - } - return eDynamicIsSet(eFeature); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public void eSet(EStructuralFeature eFeature, Object newValue) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.MODULE_MAPPING__PROJECT_NAME : - setProjectName((String) newValue); - return; - case ModulemapPackage.MODULE_MAPPING__MODULE : - setModule((Module) newValue); - return; - } - eDynamicSet(eFeature, newValue); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public void eUnset(EStructuralFeature eFeature) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.MODULE_MAPPING__PROJECT_NAME : - setProjectName(PROJECT_NAME_EDEFAULT); - return; - case ModulemapPackage.MODULE_MAPPING__MODULE : - setModule((Module) null); - return; - } - eDynamicUnset(eFeature); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(EARCreationResourceHandler.getString("ModuleMappingImpl_UI_0", new Object[]{projectName})); //$NON-NLS-1$ - return result.toString(); - } - -} //ModuleMappingImpl
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapAdapterFactory.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapAdapterFactory.java deleted file mode 100644 index 6bb08e6..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapAdapterFactory.java +++ /dev/null
@@ -1,136 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; -import org.eclipse.emf.ecore.EObject; - - - -/** - * @lastgen class ModulemapAdapterFactory extends AdapterFactoryImpl {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public class ModulemapAdapterFactory extends AdapterFactoryImpl { - /** - * @generated This field/method will be replaced during code generation. - */ - - /** - * @generated This field/method will be replaced during code generation. - */ - protected static ModulemapPackage modelPackage; - - /** - * @generated This field/method will be replaced during code generation. - */ - public ModulemapAdapterFactory() { - if (modelPackage == null) { - modelPackage = ModulemapPackage.eINSTANCE; - } - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject) object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch the delegates to the <code>createXXX</code> methods. <!-- begin-user-doc --> - * <!-- end-user-doc --> - * - * @generated - */ - protected ModulemapSwitch modelSwitch = new ModulemapSwitch() { - @Override - public Object caseModuleMapping(ModuleMapping object) { - return createModuleMappingAdapter(); - } - - @Override - public Object caseEARProjectMap(EARProjectMap object) { - return createEARProjectMapAdapter(); - } - - @Override - public Object caseUtilityJARMapping(UtilityJARMapping object) { - return createUtilityJARMappingAdapter(); - } - - @Override - public Object defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public Adapter createAdapter(Notifier target) { - return (Adapter) modelSwitch.doSwitch((EObject) target); - } - - - /** - * By default create methods return null so that we can easily ignore cases. It's useful to - * ignore a case when inheritance will catch all the cases anyway. - */ - - /** - * @generated This field/method will be replaced during code generation. - */ - public Adapter createEARProjectMapAdapter() { - return null; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public Adapter createModuleMappingAdapter() { - return null; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public Adapter createUtilityJARMappingAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. <!-- begin-user-doc --> This default - * implementation returns null. <!-- end-user-doc --> - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //ModulemapAdapterFactory
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapFactory.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapFactory.java deleted file mode 100644 index 33a1f77..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapFactory.java +++ /dev/null
@@ -1,56 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.ecore.EFactory; - - -/** - * @lastgen interface ModulemapFactory extends EFactory {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public interface ModulemapFactory extends EFactory { - /** - * The singleton instance of the factory. <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - ModulemapFactory eINSTANCE = new org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapFactoryImpl(); - - /** - * @generated This field/method will be replaced during code generation - * @return EARProjectMap value - */ - EARProjectMap createEARProjectMap(); - - /** - * @generated This field/method will be replaced during code generation - * @return ModuleMapping value - */ - ModuleMapping createModuleMapping(); - - /** - * @generated This field/method will be replaced during code generation - * @return UtilityJARMapping value - */ - UtilityJARMapping createUtilityJARMapping(); - - /** - * @generated This field/method will be replaced during code generation. - */ - ModulemapPackage getModulemapPackage(); - -} //ModulemapFactory
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapFactoryImpl.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapFactoryImpl.java deleted file mode 100644 index c56ae94..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapFactoryImpl.java +++ /dev/null
@@ -1,93 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.impl.EFactoryImpl; - - - -/** - * @lastgen class ModulemapFactoryImpl extends EFactoryImpl implements ModulemapFactory, EFactory {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public class ModulemapFactoryImpl extends EFactoryImpl implements ModulemapFactory { - - /** - * @generated This field/method will be replaced during code generation. - */ - public ModulemapFactoryImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case ModulemapPackage.MODULE_MAPPING : - return createModuleMapping(); - case ModulemapPackage.EAR_PROJECT_MAP : - return createEARProjectMap(); - case ModulemapPackage.UTILITY_JAR_MAPPING : - return createUtilityJARMapping(); - } - return null; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EARProjectMap createEARProjectMap() { - EARProjectMapImpl earProjectMap = new EARProjectMapImpl(); - return earProjectMap; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public ModuleMapping createModuleMapping() { - ModuleMappingImpl moduleMapping = new ModuleMappingImpl(); - return moduleMapping; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public UtilityJARMapping createUtilityJARMapping() { - UtilityJARMappingImpl utilityJARMapping = new UtilityJARMappingImpl(); - return utilityJARMapping; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public ModulemapPackage getModulemapPackage() { - return (ModulemapPackage) getEPackage(); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public static ModulemapPackage getPackage() { - return ModulemapPackage.eINSTANCE; - } - -} //ModulemapFactoryImpl
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapInit.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapInit.java deleted file mode 100644 index 78a5aed..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapInit.java +++ /dev/null
@@ -1,57 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2006 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - - -import org.eclipse.emf.ecore.EFactory; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.wst.common.internal.emf.utilities.ExtendedEcoreUtil; - -//import com.ibm.etools.j2ee.internal.project.EAREditModel; -/** -* @deprecated -* Use -* <p> -* Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules -* as with the Flexible project changes a .modulemaps file will not exist in an EAR module and -* all the info that was captured in .modulemaps file will is now captured in the .component file -*/ - -public class ModulemapInit { - protected static boolean initialized = false; - - public static void init() { - init(true); - } - - public static void init(boolean shouldPreRegisterPackages) { - if (!initialized) { - initialized = true; - invokePrereqInits(shouldPreRegisterPackages); - if (shouldPreRegisterPackages) { - ExtendedEcoreUtil.preRegisterPackage("modulemap.xmi", new EPackage.Descriptor() { //$NON-NLS-1$ - public EPackage getEPackage() { - return ModulemapPackage.eINSTANCE; - } - public EFactory getEFactory() { - return ModulemapFactory.eINSTANCE; - } - }); - } - //ResourceDependencyRegister.registerDependency(J2EEConstants.APPLICATION_DD_URI_OBJ, EAREditModel.MODULE_MAP_URI_OBJ); - } - } - - public static void invokePrereqInits(boolean shouldPreRegisterPackages) { - //TODO Should remove.... - //com.ibm.ejs.models.base.extensions.init.ExtensionsInit.init(shouldPreRegisterPackages); - } -}
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapPackage.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapPackage.java deleted file mode 100644 index 638f73a..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapPackage.java +++ /dev/null
@@ -1,181 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - - -/** - * @lastgen interface ModulemapPackage extends EPackage {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public interface ModulemapPackage extends EPackage { - /** - * The package name. <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - String eNAME = "modulemap"; //$NON-NLS-1$ - - /** - * @generated This field/method will be replaced during code generation. - */ - - - /** - * @generated This field/method will be replaced during code generation. - */ - int EAR_PROJECT_MAP = 1; - /** - * @generated This field/method will be replaced during code generation. - */ - int MODULE_MAPPING = 0; - /** - * @generated This field/method will be replaced during code generation. - */ - int MODULE_MAPPING__PROJECT_NAME = 0; - /** - * @generated This field/method will be replaced during code generation. - */ - int MODULE_MAPPING__MODULE = 1; - - /** - * The number of structural features of the the '<em>Module Mapping</em>' class. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int MODULE_MAPPING_FEATURE_COUNT = 2; - - /** - * @generated This field/method will be replaced during code generation. - */ - int EAR_PROJECT_MAP__MAPPINGS = 0; - /** - * @generated This field/method will be replaced during code generation. - */ - int EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS = 1; - - /** - * The number of structural features of the the '<em>EAR Project Map</em>' class. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int EAR_PROJECT_MAP_FEATURE_COUNT = 2; - - /** - * @generated This field/method will be replaced during code generation. - */ - int UTILITY_JAR_MAPPING = 2; - /** - * @generated This field/method will be replaced during code generation. - */ - int UTILITY_JAR_MAPPING__PROJECT_NAME = 0; - /** - * @generated This field/method will be replaced during code generation. - */ - int UTILITY_JAR_MAPPING__URI = 1; - - - /** - * The number of structural features of the the '<em>Utility JAR Mapping</em>' class. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @generated - * @ordered - */ - int UTILITY_JAR_MAPPING_FEATURE_COUNT = 2; - - - /** - * @generated This field/method will be replaced during code generation. - */ - String eNS_URI = "modulemap.xmi"; //$NON-NLS-1$ - /** - * The package namespace name. <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - String eNS_PREFIX = "modulemap"; //$NON-NLS-1$ - - /** - * The singleton instance of the package. <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - ModulemapPackage eINSTANCE = org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapPackageImpl.init(); - - /** - * @generated This field/method will be replaced during code generation - * @return EARProjectMap object - */ - EClass getEARProjectMap(); - - /** - * @generated This field/method will be replaced during code generation. - */ - EReference getEARProjectMap_Mappings(); - - /** - * @generated This field/method will be replaced during code generation. - */ - EReference getEARProjectMap_UtilityJARMappings(); - - /** - * @generated This field/method will be replaced during code generation - * @return ModuleMapping object - */ - EClass getModuleMapping(); - - /** - * @generated This field/method will be replaced during code generation. - */ - EAttribute getModuleMapping_ProjectName(); - - /** - * @generated This field/method will be replaced during code generation. - */ - EReference getModuleMapping_Module(); - - /** - * @generated This field/method will be replaced during code generation - * @return UtilityJARMapping object - */ - EClass getUtilityJARMapping(); - - /** - * @generated This field/method will be replaced during code generation. - */ - EAttribute getUtilityJARMapping_ProjectName(); - - /** - * @generated This field/method will be replaced during code generation. - */ - EAttribute getUtilityJARMapping_Uri(); - - /** - * @generated This field/method will be replaced during code generation. - */ - ModulemapFactory getModulemapFactory(); - -} //ModulemapPackage
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapPackageImpl.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapPackageImpl.java deleted file mode 100644 index 276a04d..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapPackageImpl.java +++ /dev/null
@@ -1,238 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2006 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.impl.EPackageImpl; -import org.eclipse.emf.ecore.impl.EcorePackageImpl; -import org.eclipse.jem.java.internal.impl.JavaRefPackageImpl; -import org.eclipse.jst.j2ee.application.ApplicationPackage; -import org.eclipse.jst.j2ee.application.internal.impl.ApplicationPackageImpl; -import org.eclipse.jst.j2ee.common.internal.impl.CommonPackageImpl; - - - -/** - * @lastgen class ModulemapPackageImpl extends EPackageImpl implements ModulemapPackage, EPackage {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public class ModulemapPackageImpl extends EPackageImpl implements ModulemapPackage { - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - private EClass moduleMappingEClass = null; - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - private EClass earProjectMapEClass = null; - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - private EClass utilityJARMappingEClass = null; - - /** - * @generated This field/method will be replaced during code generation. - */ - private ModulemapPackageImpl() { - super(eNS_URI, ModulemapFactory.eINSTANCE); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public static ModulemapPackage init() { - // Initialize simple dependencies - CommonPackageImpl.init(); - JavaRefPackageImpl.init(); - ApplicationPackageImpl.init(); - EcorePackageImpl.init(); - - // Obtain or create and register package and interdependencies - ModulemapPackageImpl theModulemapPackage = (ModulemapPackageImpl) (EPackage.Registry.INSTANCE.getEPackage(eNS_URI) != null ? EPackage.Registry.INSTANCE.getEPackage(eNS_URI) : new ModulemapPackageImpl()); - - // Step 1: create meta-model objects - theModulemapPackage.createPackageContents(); - - // Step 2: complete initialization - theModulemapPackage.initializePackageContents(); - - return theModulemapPackage; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EClass getEARProjectMap() { - return earProjectMapEClass; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EReference getEARProjectMap_Mappings() { - return earProjectMapEClass.getEReferences().get(0); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EReference getEARProjectMap_UtilityJARMappings() { - return earProjectMapEClass.getEReferences().get(1); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EClass getModuleMapping() { - return moduleMappingEClass; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EAttribute getModuleMapping_ProjectName() { - return moduleMappingEClass.getEAttributes().get(0); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EReference getModuleMapping_Module() { - return moduleMappingEClass.getEReferences().get(0); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EClass getUtilityJARMapping() { - return utilityJARMappingEClass; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EAttribute getUtilityJARMapping_ProjectName() { - return utilityJARMappingEClass.getEAttributes().get(0); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public EAttribute getUtilityJARMapping_Uri() { - return utilityJARMappingEClass.getEAttributes().get(1); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public ModulemapFactory getModulemapFactory() { - return (ModulemapFactory) getEFactoryInstance(); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is guarded to have no affect on - * any invocation but its first. <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - public void createPackageContents() { - if (isCreated) - return; - isCreated = true; - - // Create classes and their features - moduleMappingEClass = createEClass(MODULE_MAPPING); - createEAttribute(moduleMappingEClass, MODULE_MAPPING__PROJECT_NAME); - createEReference(moduleMappingEClass, MODULE_MAPPING__MODULE); - - earProjectMapEClass = createEClass(EAR_PROJECT_MAP); - createEReference(earProjectMapEClass, EAR_PROJECT_MAP__MAPPINGS); - createEReference(earProjectMapEClass, EAR_PROJECT_MAP__UTILITY_JAR_MAPPINGS); - - utilityJARMappingEClass = createEClass(UTILITY_JAR_MAPPING); - createEAttribute(utilityJARMappingEClass, UTILITY_JAR_MAPPING__PROJECT_NAME); - createEAttribute(utilityJARMappingEClass, UTILITY_JAR_MAPPING__URI); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This method is guarded to have - * no affect on any invocation but its first. <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) - return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Obtain other dependent packages - // CommonPackageImpl theCommonPackage = - // (CommonPackageImpl)EPackage.Registry.INSTANCE.getEPackage(CommonPackage.eNS_URI); - // JavaRefPackageImpl theJavaRefPackage = - // (JavaRefPackageImpl)EPackage.Registry.INSTANCE.getEPackage(JavaRefPackage.eNS_URI); - ApplicationPackageImpl theApplicationPackage = (ApplicationPackageImpl) EPackage.Registry.INSTANCE.getEPackage(ApplicationPackage.eNS_URI); - // EcorePackageImpl theEcorePackage = - // (EcorePackageImpl)EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI); - - // Add supertypes to classes - - // Initialize classes and features; add operations and parameters - initEClass(moduleMappingEClass, ModuleMapping.class, "ModuleMapping", !IS_ABSTRACT, !IS_INTERFACE); //$NON-NLS-1$ - initEAttribute(getModuleMapping_ProjectName(), ecorePackage.getEString(), "projectName", null, 0, 1, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, true, false); //$NON-NLS-1$ - initEReference(getModuleMapping_Module(), theApplicationPackage.getModule(), null, "module", null, 1, 1, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, true, false); //$NON-NLS-1$ - - initEClass(earProjectMapEClass, EARProjectMap.class, "EARProjectMap", !IS_ABSTRACT, !IS_INTERFACE); //$NON-NLS-1$ - initEReference(getEARProjectMap_Mappings(), this.getModuleMapping(), null, "mappings", null, 0, -1, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, true, false); //$NON-NLS-1$ - initEReference(getEARProjectMap_UtilityJARMappings(), this.getUtilityJARMapping(), null, "utilityJARMappings", null, 1, -1, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, true, false); //$NON-NLS-1$ - - initEClass(utilityJARMappingEClass, UtilityJARMapping.class, "UtilityJARMapping", !IS_ABSTRACT, !IS_INTERFACE); //$NON-NLS-1$ - initEAttribute(getUtilityJARMapping_ProjectName(), ecorePackage.getEString(), "projectName", null, 0, 1, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, true, false); //$NON-NLS-1$ - initEAttribute(getUtilityJARMapping_Uri(), ecorePackage.getEString(), "uri", null, 0, 1, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, true, false); //$NON-NLS-1$ - - // Create resource - createResource(eNS_URI); - } -} //ModulemapPackageImpl
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapSwitch.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapSwitch.java deleted file mode 100644 index ff5df4d..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/ModulemapSwitch.java +++ /dev/null
@@ -1,107 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; - - - -/** - * @lastgen class ModulemapSwitch {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public class ModulemapSwitch { - /** - * The cached model package <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - protected static ModulemapPackage modelPackage; - - /** - * @generated This field/method will be replaced during code generation. - */ - public ModulemapSwitch() { - if (modelPackage == null) { - modelPackage = ModulemapPackage.eINSTANCE; - } - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public Object doSwitch(EObject theEObject) { - EClass theEClass = theEObject.eClass(); - if (theEClass.eContainer() == modelPackage) { - switch (theEClass.getClassifierID()) { - case ModulemapPackage.MODULE_MAPPING : { - ModuleMapping moduleMapping = (ModuleMapping) theEObject; - Object result = caseModuleMapping(moduleMapping); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case ModulemapPackage.EAR_PROJECT_MAP : { - EARProjectMap earProjectMap = (EARProjectMap) theEObject; - Object result = caseEARProjectMap(earProjectMap); - if (result == null) - result = defaultCase(theEObject); - return result; - } - case ModulemapPackage.UTILITY_JAR_MAPPING : { - UtilityJARMapping utilityJARMapping = (UtilityJARMapping) theEObject; - Object result = caseUtilityJARMapping(utilityJARMapping); - if (result == null) - result = defaultCase(theEObject); - return result; - } - default : - return defaultCase(theEObject); - } - } - return defaultCase(theEObject); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public Object caseEARProjectMap(EARProjectMap object) { - return null; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public Object caseModuleMapping(ModuleMapping object) { - return null; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public Object caseUtilityJARMapping(UtilityJARMapping object) { - return null; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public Object defaultCase(EObject object) { - return null; - } - -} //ModulemapSwitch
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/UtilityJARMapping.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/UtilityJARMapping.java deleted file mode 100644 index e523561..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/UtilityJARMapping.java +++ /dev/null
@@ -1,53 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - - -import org.eclipse.emf.ecore.EObject; - - -/** - * @lastgen interface UtilityJARMapping extends EObject {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public interface UtilityJARMapping extends EObject { - /** - * @generated This field/method will be replaced during code generation - * @return The value of the ProjectName attribute - */ - String getProjectName(); - - /** - * @generated This field/method will be replaced during code generation - * @param value - * The new value of the ProjectName attribute - */ - void setProjectName(String value); - - /** - * @generated This field/method will be replaced during code generation - * @return The value of the Uri attribute - */ - String getUri(); - - /** - * @generated This field/method will be replaced during code generation - * @param value - * The new value of the Uri attribute - */ - void setUri(String value); - -} //UtilityJARMapping
diff --git a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/UtilityJARMappingImpl.java b/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/UtilityJARMappingImpl.java deleted file mode 100644 index 971760a..0000000 --- a/plugins/org.eclipse.jst.j2ee/earproject/org/eclipse/jst/j2ee/internal/earcreation/modulemap/UtilityJARMappingImpl.java +++ /dev/null
@@ -1,189 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2003, 2005 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.jst.j2ee.internal.earcreation.modulemap; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.EObjectImpl; -import org.eclipse.jst.j2ee.internal.earcreation.EARCreationResourceHandler; - - -/** - * @lastgen class UtilityJARMappingImpl extends EObjectImpl implements UtilityJARMapping, EObject {} - * @deprecated - * Use - * <p> - * Need to use the ModuleCore and WorkbenchComponent Api to get to the referenced modules - * as with the Flexible project changes a .modulemaps file will not exist in an EAR module and - * all the info that was captured in .modulemaps file will is now captured in the .component file - */ -public class UtilityJARMappingImpl extends EObjectImpl implements UtilityJARMapping { - /** - * The default value of the '{@link #getProjectName() <em>Project Name</em>}' attribute. <!-- - * begin-user-doc --> <!-- end-user-doc --> - * - * @see #getProjectName() - * @generated - * @ordered - */ - protected static final String PROJECT_NAME_EDEFAULT = null; - - /** - * @generated This field/method will be replaced during code generation. - */ - /** - * @generated This field/method will be replaced during code generation. - */ - protected String projectName = PROJECT_NAME_EDEFAULT; - /** - * The default value of the '{@link #getUri() <em>Uri</em>}' attribute. <!-- begin-user-doc - * --> <!-- end-user-doc --> - * - * @see #getUri() - * @generated - * @ordered - */ - protected static final String URI_EDEFAULT = null; - - /** - * @generated This field/method will be replaced during code generation. - */ - protected String uri = URI_EDEFAULT; - - /** - * @generated This field/method will be replaced during code generation. - */ - protected UtilityJARMappingImpl() { - super(); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return ModulemapPackage.eINSTANCE.getUtilityJARMapping(); - } - - /** - * @generated This field/method will be replaced during code generation - */ - public String getProjectName() { - return projectName; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public void setProjectName(String newProjectName) { - String oldProjectName = projectName; - projectName = newProjectName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModulemapPackage.UTILITY_JAR_MAPPING__PROJECT_NAME, oldProjectName, projectName)); - } - - /** - * @generated This field/method will be replaced during code generation - */ - public String getUri() { - return uri; - } - - /** - * @generated This field/method will be replaced during code generation. - */ - public void setUri(String newUri) { - String oldUri = uri; - uri = newUri; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, ModulemapPackage.UTILITY_JAR_MAPPING__URI, oldUri, uri)); - } - - /** - * <!-- begin-user-doc --> <!-- end-user-doc --> - * - * @generated - */ - @Override - public Object eGet(EStructuralFeature eFeature, boolean resolve) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.UTILITY_JAR_MAPPING__PROJECT_NAME : - return getProjectName(); - case ModulemapPackage.UTILITY_JAR_MAPPING__URI : - return getUri(); - } - return eDynamicGet(eFeature, resolve); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public boolean eIsSet(EStructuralFeature eFeature) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.UTILITY_JAR_MAPPING__PROJECT_NAME : - return PROJECT_NAME_EDEFAULT == null ? projectName != null : !PROJECT_NAME_EDEFAULT.equals(projectName); - case ModulemapPackage.UTILITY_JAR_MAPPING__URI : - return URI_EDEFAULT == null ? uri != null : !URI_EDEFAULT.equals(uri); - } - return eDynamicIsSet(eFeature); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public void eSet(EStructuralFeature eFeature, Object newValue) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.UTILITY_JAR_MAPPING__PROJECT_NAME : - setProjectName((String) newValue); - return; - case ModulemapPackage.UTILITY_JAR_MAPPING__URI : - setUri((String) newValue); - return; - } - eDynamicSet(eFeature, newValue); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public void eUnset(EStructuralFeature eFeature) { - switch (eDerivedStructuralFeatureID(eFeature.getFeatureID(), eFeature.getContainerClass())) { - case ModulemapPackage.UTILITY_JAR_MAPPING__PROJECT_NAME : - setProjectName(PROJECT_NAME_EDEFAULT); - return; - case ModulemapPackage.UTILITY_JAR_MAPPING__URI : - setUri(URI_EDEFAULT); - return; - } - eDynamicUnset(eFeature); - } - - /** - * @generated This field/method will be replaced during code generation. - */ - @Override - public String toString() { - if (eIsProxy()) - return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(EARCreationResourceHandler.getString("UtilityJARMappingImpl_UI_0", new Object[]{projectName, uri})); //$NON-NLS-1$ - return result.toString(); - } - -} //UtilityJARMappingImpl
diff --git a/plugins/org.eclipse.jst.j2ee/j2eeplugin/org/eclipse/jst/j2ee/internal/plugin/J2EEPlugin.java b/plugins/org.eclipse.jst.j2ee/j2eeplugin/org/eclipse/jst/j2ee/internal/plugin/J2EEPlugin.java index f227065..2c73d69 100644 --- a/plugins/org.eclipse.jst.j2ee/j2eeplugin/org/eclipse/jst/j2ee/internal/plugin/J2EEPlugin.java +++ b/plugins/org.eclipse.jst.j2ee/j2eeplugin/org/eclipse/jst/j2ee/internal/plugin/J2EEPlugin.java
@@ -510,9 +510,6 @@ //Have to do the next line immediately to fix timing problems with factory registration ArchiveInit.init(false); - //ModuleMaps are the maps from modules in an ear project to the j2ee projects for the - // modules - org.eclipse.jst.j2ee.internal.earcreation.modulemap.ModulemapInit.init(false); ensureFactoryRegistration(); ValidatorManager.setResourceUtilClass(ResourceUtil.class); IAdapterManager manager = Platform.getAdapterManager();