diff options
author | Ed Merks | 2013-10-24 10:31:23 +0000 |
---|---|---|
committer | Ed Merks | 2013-10-24 10:31:23 +0000 |
commit | 69a6998c37f06a8cf1faaeffdc3f7567ace7857a (patch) | |
tree | 60593bb2414f0c1e6f3e94a01acc05be52d37e93 | |
parent | ee878758bbff4a2d719788b20667f8bc759b0f73 (diff) | |
download | cdo-69a6998c37f06a8cf1faaeffdc3f7567ace7857a.tar.gz cdo-69a6998c37f06a8cf1faaeffdc3f7567ace7857a.tar.xz cdo-69a6998c37f06a8cf1faaeffdc3f7567ace7857a.zip |
Improve setup related models
28 files changed, 898 insertions, 124 deletions
diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/icons/full/obj16/ContextVariableTask.gif b/plugins/org.eclipse.emf.cdo.releng.setup.edit/icons/full/obj16/ContextVariableTask.gif Binary files differnew file mode 100644 index 0000000000..3a1b314283 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/icons/full/obj16/ContextVariableTask.gif diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/plugin.properties b/plugins/org.eclipse.emf.cdo.releng.setup.edit/plugin.properties index ee859aa237..723d3c0fab 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup.edit/plugin.properties +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/plugin.properties @@ -121,3 +121,8 @@ _UI_Unknown_type = Object _UI_WorkingSetTask_type = Working Sets _UI_WorkingSetTask_workingSetGroup_feature = Working Sets _UI_WorkingSetTask_workingSets_feature = Working Sets +_UI_ContextVariableTask_type = Context Variable +_UI_EclipseIniTask_value_feature = Value +_UI_ResourceCopyTask_sourceURL_feature = Source URL +_UI_ContextVariableTask_name_feature = Name +_UI_ContextVariableTask_value_feature = Value diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/CompoundSetupTaskItemProvider.java b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/CompoundSetupTaskItemProvider.java index 248215e37b..7079c982d4 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/CompoundSetupTaskItemProvider.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/CompoundSetupTaskItemProvider.java @@ -219,6 +219,9 @@ public class CompoundSetupTaskItemProvider extends SetupTaskItemProvider impleme newChildDescriptors.add(createChildParameter(SetupPackage.Literals.SETUP_TASK_CONTAINER__SETUP_TASKS, SetupFactory.eINSTANCE.createKeyBindingTask())); + + newChildDescriptors.add(createChildParameter(SetupPackage.Literals.SETUP_TASK_CONTAINER__SETUP_TASKS, + SetupFactory.eINSTANCE.createContextVariableTask())); } } diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/ContextVariableTaskItemProvider.java b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/ContextVariableTaskItemProvider.java new file mode 100644 index 0000000000..08cac7ea59 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/ContextVariableTaskItemProvider.java @@ -0,0 +1,169 @@ +/** + */ +package org.eclipse.emf.cdo.releng.setup.provider; + +import org.eclipse.emf.cdo.releng.setup.ContextVariableTask; +import org.eclipse.emf.cdo.releng.setup.SetupPackage; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +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.IItemPropertyDescriptor; +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.emf.edit.provider.ViewerNotification; + +import org.eclipse.core.runtime.Path; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class ContextVariableTaskItemProvider extends SetupTaskItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ContextVariableTaskItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addNamePropertyDescriptor(object); + addValuePropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Name feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addNamePropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_ContextVariableTask_name_feature"), + getString("_UI_PropertyDescriptor_description", "_UI_ContextVariableTask_name_feature", + "_UI_ContextVariableTask_type"), SetupPackage.Literals.CONTEXT_VARIABLE_TASK__NAME, true, false, false, + ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); + } + + /** + * This adds a property descriptor for the Value feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addValuePropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_ContextVariableTask_value_feature"), + getString("_UI_PropertyDescriptor_description", "_UI_ContextVariableTask_value_feature", + "_UI_ContextVariableTask_type"), SetupPackage.Literals.CONTEXT_VARIABLE_TASK__VALUE, true, false, false, + ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); + } + + /** + * This returns ContextVariableTask.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getImage(Object object) + { + return overlayImage(object, getResourceLocator().getImage("full/obj16/ContextVariableTask")); + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated NOT + */ + @Override + public String getText(Object object) + { + String name = ((ContextVariableTask)object).getName(); + String value = ((ContextVariableTask)object).getValue(); + + if (name != null && name.length() != 0) + { + name = new Path(name).lastSegment(); + } + else if (value == null || value.length() == 0) + { + return getString("_UI_ContextVariableTask_type"); + } + + return "" + name + " = " + value; + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + + switch (notification.getFeatureID(ContextVariableTask.class)) + { + case SetupPackage.CONTEXT_VARIABLE_TASK__NAME: + case SetupPackage.CONTEXT_VARIABLE_TASK__VALUE: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/KeyBindingTaskItemProvider.java b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/KeyBindingTaskItemProvider.java index 940f18bbe7..db67d7a82e 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/KeyBindingTaskItemProvider.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/KeyBindingTaskItemProvider.java @@ -5,7 +5,6 @@ package org.eclipse.emf.cdo.releng.setup.provider; import org.eclipse.emf.cdo.releng.setup.KeyBindingTask; import org.eclipse.emf.cdo.releng.setup.SetupFactory; import org.eclipse.emf.cdo.releng.setup.SetupPackage; - import org.eclipse.emf.common.notify.AdapterFactory; import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.ecore.EStructuralFeature; @@ -18,7 +17,6 @@ import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; import org.eclipse.emf.edit.provider.ITreeItemContentProvider; import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; import org.eclipse.emf.edit.provider.ViewerNotification; - import java.util.Collection; import java.util.List; diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/P2TaskItemProvider.java b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/P2TaskItemProvider.java index 9e4f937c2e..1edf83d659 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/P2TaskItemProvider.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/P2TaskItemProvider.java @@ -13,7 +13,6 @@ package org.eclipse.emf.cdo.releng.setup.provider; import org.eclipse.emf.cdo.releng.setup.P2Task; import org.eclipse.emf.cdo.releng.setup.SetupFactory; import org.eclipse.emf.cdo.releng.setup.SetupPackage; - import org.eclipse.emf.common.notify.AdapterFactory; import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.ecore.EStructuralFeature; @@ -24,7 +23,6 @@ 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.ViewerNotification; - import java.util.Collection; import java.util.List; diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupItemProviderAdapterFactory.java index 693b7bd2cf..d105513b7c 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupItemProviderAdapterFactory.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupItemProviderAdapterFactory.java @@ -497,11 +497,36 @@ public class SetupItemProviderAdapterFactory extends SetupAdapterFactory impleme } /** - * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.releng.setup.EclipseIniTask} instances. + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask} instances. * <!-- begin-user-doc --> - * <!-- end-user-doc --> + * <!-- end-user-doc --> * @generated */ + protected ContextVariableTaskItemProvider contextVariableTaskItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter createContextVariableTaskAdapter() + { + if (contextVariableTaskItemProvider == null) + { + contextVariableTaskItemProvider = new ContextVariableTaskItemProvider(this); + } + + return contextVariableTaskItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.releng.setup.EclipseIniTask} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ protected EclipseIniTaskItemProvider eclipseIniTaskItemProvider; /** @@ -858,6 +883,8 @@ public class SetupItemProviderAdapterFactory extends SetupAdapterFactory impleme keyBindingTaskItemProvider.dispose(); if (commandParameterItemProvider != null) commandParameterItemProvider.dispose(); + if (contextVariableTaskItemProvider != null) + contextVariableTaskItemProvider.dispose(); } } diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupTaskContainerItemProvider.java b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupTaskContainerItemProvider.java index b0a10d3870..20a140c71b 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupTaskContainerItemProvider.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/SetupTaskContainerItemProvider.java @@ -195,6 +195,9 @@ public class SetupTaskContainerItemProvider extends ItemProviderAdapter implemen newChildDescriptors.add(createChildParameter(SetupPackage.Literals.SETUP_TASK_CONTAINER__SETUP_TASKS, SetupFactory.eINSTANCE.createKeyBindingTask())); + + newChildDescriptors.add(createChildParameter(SetupPackage.Literals.SETUP_TASK_CONTAINER__SETUP_TASKS, + SetupFactory.eINSTANCE.createContextVariableTask())); } /** diff --git a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/WorkingSetTaskItemProvider.java b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/WorkingSetTaskItemProvider.java index aeea9d1b19..08d0c02956 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/WorkingSetTaskItemProvider.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup.edit/src/org/eclipse/emf/cdo/releng/setup/provider/WorkingSetTaskItemProvider.java @@ -13,7 +13,6 @@ package org.eclipse.emf.cdo.releng.setup.provider; import org.eclipse.emf.cdo.releng.setup.SetupPackage; import org.eclipse.emf.cdo.releng.setup.WorkingSetTask; import org.eclipse.emf.cdo.releng.workingsets.WorkingSetsFactory; - import org.eclipse.emf.common.notify.AdapterFactory; import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.ecore.EStructuralFeature; @@ -24,7 +23,6 @@ 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.ViewerNotification; - import java.util.Collection; import java.util.List; diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.cdo.releng.setup/META-INF/MANIFEST.MF index b1722d1fc2..c8145eee02 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/META-INF/MANIFEST.MF +++ b/plugins/org.eclipse.emf.cdo.releng.setup/META-INF/MANIFEST.MF @@ -8,33 +8,33 @@ Bundle-Vendor: %providerName Bundle-Localization: plugin Require-Bundle: org.eclipse.net4j.util;bundle-version="[3.0.0,4.0.0)", org.eclipse.core.runtime;bundle-version="[3.5.0,4.0.0)", - org.eclipse.emf.cdo.releng.workingsets;bundle-version="[1.0.0,2.0.0)";visibility:=reexport, - org.eclipse.emf.cdo.releng.predicates;bundle-version="[1.0.0,2.0.0)";visibility:=reexport, - org.eclipse.emf.ecore;bundle-version="[2.5.0,3.0.0)";visibility:=reexport, + org.eclipse.emf.cdo.releng.workingsets;visibility:=reexport;bundle-version="[1.0.0,2.0.0)", + org.eclipse.emf.cdo.releng.predicates;visibility:=reexport;bundle-version="[1.0.0,2.0.0)", + org.eclipse.emf.ecore;visibility:=reexport;bundle-version="[2.5.0,3.0.0)", org.eclipse.emf.ecore.xmi;bundle-version="[2.5.0,3.0.0)", - org.eclipse.core.resources;bundle-version="[3.5.0,4.0.0)";resolution:=optional, - org.eclipse.core.variables;bundle-version="[3.0.0,4.0.0)";resolution:=optional, - org.eclipse.pde.core;bundle-version="[3.5.0,4.0.0)";resolution:=optional, - org.eclipse.pde.api.tools;bundle-version="[1.0.0,2.0.0)";resolution:=optional, - org.eclipse.team.ui;bundle-version="[3.5.0,4.0.0)";resolution:=optional, - javaewah;bundle-version="[0.0.0,1.0.0)";resolution:=optional, - org.eclipse.jgit;bundle-version="[3.0.0,4.0.0)";resolution:=optional, - org.eclipse.egit;bundle-version="[3.0.0,4.0.0)";resolution:=optional, - org.eclipse.egit.core;bundle-version="[3.0.0,4.0.0)";resolution:=optional, - org.eclipse.egit.ui;bundle-version="[3.0.0,4.0.0)";resolution:=optional, - org.eclipse.emf.edit.ui;bundle-version="[2.5.0,3.0.0)";resolution:=optional, - org.eclipse.ecf.provider.filetransfer;bundle-version="[3.2.0,4.0.0)";resolution:=optional, - org.eclipse.ecf.filetransfer;bundle-version="[5.0.0,6.0.0)";resolution:=optional, - org.eclipse.ecf.identity;bundle-version="[3.2.0,4.0.0)";resolution:=optional, - org.eclipse.ecf;bundle-version="[3.2.0,4.0.0)";resolution:=optional, - org.eclipse.buckminster.sax;bundle-version="[1.0.0,2.0.0)";resolution:=optional, - org.eclipse.buckminster.cmdline;bundle-version="[1.0.0,2.0.0)";resolution:=optional, - org.eclipse.buckminster.download;bundle-version="[1.0.0,2.0.0)";resolution:=optional, - org.eclipse.buckminster.runtime;bundle-version="[1.0.0,2.0.0)";resolution:=optional, - org.eclipse.buckminster.core;bundle-version="[1.0.0,2.0.0)";resolution:=optional, - org.eclipse.buckminster.pde;bundle-version="[1.0.0,2.0.0)";resolution:=optional, + org.eclipse.core.resources;resolution:=optional;bundle-version="[3.5.0,4.0.0)", + org.eclipse.core.variables;resolution:=optional;bundle-version="[3.0.0,4.0.0)", + org.eclipse.pde.core;resolution:=optional;bundle-version="[3.5.0,4.0.0)", + org.eclipse.pde.api.tools;resolution:=optional;bundle-version="[1.0.0,2.0.0)", + org.eclipse.team.ui;resolution:=optional;bundle-version="[3.5.0,4.0.0)", + javaewah;resolution:=optional;bundle-version="[0.0.0,1.0.0)", + org.eclipse.jgit;resolution:=optional;bundle-version="[3.0.0,4.0.0)", + org.eclipse.egit;resolution:=optional;bundle-version="[3.0.0,4.0.0)", + org.eclipse.egit.core;resolution:=optional;bundle-version="[3.0.0,4.0.0)", + org.eclipse.egit.ui;resolution:=optional;bundle-version="[3.0.0,4.0.0)", + org.eclipse.emf.edit.ui;resolution:=optional;bundle-version="[2.5.0,3.0.0)", + org.eclipse.ecf.provider.filetransfer;resolution:=optional;bundle-version="[3.2.0,4.0.0)", + org.eclipse.ecf.filetransfer;resolution:=optional;bundle-version="[5.0.0,6.0.0)", + org.eclipse.ecf.identity;resolution:=optional;bundle-version="[3.2.0,4.0.0)", + org.eclipse.ecf;resolution:=optional;bundle-version="[3.2.0,4.0.0)", + org.eclipse.buckminster.sax;resolution:=optional;bundle-version="[1.0.0,2.0.0)", + org.eclipse.buckminster.cmdline;resolution:=optional;bundle-version="[1.0.0,2.0.0)", + org.eclipse.buckminster.download;resolution:=optional;bundle-version="[1.0.0,2.0.0)", + org.eclipse.buckminster.runtime;resolution:=optional;bundle-version="[1.0.0,2.0.0)", + org.eclipse.buckminster.core;resolution:=optional;bundle-version="[1.0.0,2.0.0)", + org.eclipse.buckminster.pde;resolution:=optional;bundle-version="[1.0.0,2.0.0)", org.eclipse.equinox.p2.core;bundle-version="[2.0.0,3.0.0)", - org.eclipse.equinox.p2.ui;bundle-version="[2.0.0,3.0.0)";resolution:=optional, + org.eclipse.equinox.p2.ui;resolution:=optional;bundle-version="[2.0.0,3.0.0)", org.eclipse.equinox.p2.metadata;bundle-version="[2.0.0,3.0.0)", org.eclipse.equinox.p2.repository;bundle-version="[2.0.0,3.0.0)", org.eclipse.equinox.p2.artifact.repository;bundle-version="[1.0.0,2.0.0)", diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/model/Configuration.setup b/plugins/org.eclipse.emf.cdo.releng.setup/model/Configuration.setup index 2e00a36642..c7b1903f29 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/model/Configuration.setup +++ b/plugins/org.eclipse.emf.cdo.releng.setup/model/Configuration.setup @@ -27,9 +27,9 @@ <setupTasks xsi:type="setup:EclipsePreferenceTask" key="/instance/org.eclipse.ui.ide/WORKSPACE_NAME" value="${setup.project.name} ${setup.branch.name|cap}"/> </eclipseVersions> <eclipseVersions version="4.4"> - <setupTasks xsi:type="setup:StringVariableTask" name="train.name" value="Luna" description="The name of the release train"/> - <setupTasks xsi:type="setup:StringVariableTask" requirements="//@eclipseVersions.2/@setupTasks.0" name="train.url" value="http://download.eclipse.org/releases/${train.name|lower}" description="The URL of the release train p2 repository"/> - <setupTasks xsi:type="setup:StringVariableTask" requirements="//@eclipseVersions.2/@setupTasks.1" name="platform.url" value="${train.url}" description="The location of the Eclipse SDK's p2 repository"/> + <setupTasks xsi:type="setup:ContextVariableTask" name="train.name" value="Luna"/> + <setupTasks xsi:type="setup:ContextVariableTask" requirements="//@eclipseVersions.2/@setupTasks.0" name="train.url" value="http://download.eclipse.org/releases/${train.name|lower}"/> + <setupTasks xsi:type="setup:ContextVariableTask" requirements="//@eclipseVersions.2/@setupTasks.1" name="platform.url" value="${train.url}"/> <setupTasks xsi:type="setup:P2Task" requirements="//@eclipseVersions.2/@setupTasks.2"> <p2Repositories url="${platform.url}"/> <p2Repositories url="${releng.url}"/> diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecore b/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecore index 23b00e7232..ecf6d9a301 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecore +++ b/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecore @@ -167,4 +167,8 @@ <eClassifiers xsi:type="ecore:EDataType" name="TriggerSet" instanceTypeName="java.util.Set<org.eclipse.emf.cdo.releng.setup.Trigger>"/> <eClassifiers xsi:type="ecore:EDataType" name="Exception" instanceClassName="java.lang.Exception"/> <eClassifiers xsi:type="ecore:EDataType" name="URI" instanceClassName="org.eclipse.emf.common.util.URI"/> + <eClassifiers xsi:type="ecore:EClass" name="ContextVariableTask" eSuperTypes="#//SetupTask"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="value" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/> + </eClassifiers> </ecore:EPackage> diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecorediag b/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecorediag index fca3763123..ba7d80732d 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecorediag +++ b/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.ecorediag @@ -501,7 +501,7 @@ </children> <styles xmi:type="notation:ShapeStyle" xmi:id="_aSLB8QmrEeOuXPWwsMY9fA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="15053796" lineColor="8421504"/> <element xmi:type="ecore:EClass" href="setup.ecore#//OneTimeSetupTask"/> - <layoutConstraint xmi:type="notation:Bounds" xmi:id="_aSLB8gmrEeOuXPWwsMY9fA" x="1055" y="605"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_aSLB8gmrEeOuXPWwsMY9fA" x="1058" y="607"/> </children> <children xmi:type="notation:Node" xmi:id="_QJaZUDWJEeO0we5dUm5hxw" type="1001"> <children xmi:type="notation:Node" xmi:id="_QJbncDWJEeO0we5dUm5hxw" type="4001"/> @@ -652,6 +652,30 @@ <element xmi:type="ecore:EClass" href="setup.ecore#//CommandParameter"/> <layoutConstraint xmi:type="notation:Bounds" xmi:id="_zKlSEjrkEeOm3ZfER1Sl2A" x="675" y="1175"/> </children> + <children xmi:type="notation:Node" xmi:id="_p1fVkDySEeORQ6467O3RjQ" type="1001"> + <children xmi:type="notation:Node" xmi:id="_p1fVkTySEeORQ6467O3RjQ" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_p1fVkjySEeORQ6467O3RjQ" type="5001"> + <children xmi:type="notation:Node" xmi:id="_p1fVkzySEeORQ6467O3RjQ" type="2001"> + <element xmi:type="ecore:EAttribute" href="setup.ecore#//ContextVariableTask/name"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_p1fVlDySEeORQ6467O3RjQ"/> + </children> + <children xmi:type="notation:Node" xmi:id="_p1fVlTySEeORQ6467O3RjQ" type="2001"> + <element xmi:type="ecore:EAttribute" href="setup.ecore#//ContextVariableTask/value"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_p1fVljySEeORQ6467O3RjQ"/> + </children> + <styles xmi:type="notation:DrawerStyle" xmi:id="_p1fVmTySEeORQ6467O3RjQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_p1fVmjySEeORQ6467O3RjQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_p1fVmzySEeORQ6467O3RjQ"/> + </children> + <children xmi:type="notation:Node" xmi:id="_p1fVnDySEeORQ6467O3RjQ" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_p1fVnTySEeORQ6467O3RjQ"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_p1fVnjySEeORQ6467O3RjQ"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_p1fVnzySEeORQ6467O3RjQ"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_p1fVoDySEeORQ6467O3RjQ" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="15053796" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="setup.ecore#//ContextVariableTask"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_p1fVoTySEeORQ6467O3RjQ" x="1020" y="960" width="198" height="93"/> + </children> <styles xmi:type="notation:DiagramStyle" xmi:id="_u_e_seoIEeKpRf481yfX-g"/> <element xmi:type="ecore:EPackage" href="setup.ecore#/"/> <edges xmi:type="notation:Edge" xmi:id="_4esFEOoIEeKpRf481yfX-g" type="3002" source="_zoytIOoIEeKpRf481yfX-g" target="_2Y42MOoIEeKpRf481yfX-g"> diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.genmodel b/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.genmodel index d07ba3b4fc..c4ce8f01cd 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.genmodel +++ b/plugins/org.eclipse.emf.cdo.releng.setup/model/setup.genmodel @@ -22,9 +22,9 @@ <genEnumLiterals ecoreEnumLiteral="setup.ecore#//Trigger/STARTUP"/> <genEnumLiterals ecoreEnumLiteral="setup.ecore#//Trigger/MANUAL"/> </genEnums> - <genDataTypes ecoreDataType="setup.ecore#//URI"/> - <genDataTypes ecoreDataType="setup.ecore#//Exception"/> <genDataTypes ecoreDataType="setup.ecore#//TriggerSet"/> + <genDataTypes ecoreDataType="setup.ecore#//Exception"/> + <genDataTypes ecoreDataType="setup.ecore#//URI"/> <genClasses ecoreClass="setup.ecore#//EclipseVersion"> <genFeatures property="None" notify="false" createChild="false" ecoreFeature="ecore:EReference setup.ecore#//EclipseVersion/configuration"/> <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//EclipseVersion/version"/> @@ -139,5 +139,22 @@ <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//TextModification/pattern"/> <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//TextModification/substitutions"/> </genClasses> + <genClasses ecoreClass="setup.ecore#//KeyBindingTask"> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//KeyBindingTask/scheme"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//KeyBindingTask/context"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//KeyBindingTask/platform"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//KeyBindingTask/locale"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//KeyBindingTask/keys"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//KeyBindingTask/command"/> + <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference setup.ecore#//KeyBindingTask/commandParameters"/> + </genClasses> + <genClasses ecoreClass="setup.ecore#//CommandParameter"> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//CommandParameter/id"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//CommandParameter/value"/> + </genClasses> + <genClasses ecoreClass="setup.ecore#//ContextVariableTask"> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//ContextVariableTask/name"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute setup.ecore#//ContextVariableTask/value"/> + </genClasses> </genPackages> </genmodel:GenModel> diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/ContextVariableTask.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/ContextVariableTask.java new file mode 100644 index 0000000000..b1c35e4241 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/ContextVariableTask.java @@ -0,0 +1,76 @@ +/** + */ +package org.eclipse.emf.cdo.releng.setup; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Context Variable Task</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getValue <em>Value</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.releng.setup.SetupPackage#getContextVariableTask() + * @model + * @generated + */ +public interface ContextVariableTask extends SetupTask +{ + /** + * Returns the value of the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Name</em>' attribute. + * @see #setName(String) + * @see org.eclipse.emf.cdo.releng.setup.SetupPackage#getContextVariableTask_Name() + * @model + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getName <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Name</em>' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + + /** + * Returns the value of the '<em><b>Value</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Value</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Value</em>' attribute. + * @see #setValue(String) + * @see org.eclipse.emf.cdo.releng.setup.SetupPackage#getContextVariableTask_Value() + * @model + * @generated + */ + String getValue(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getValue <em>Value</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Value</em>' attribute. + * @see #getValue() + * @generated + */ + void setValue(String value); + +} // ContextVariableTask diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupFactory.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupFactory.java index 3455ba33d2..75bb25c2fa 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupFactory.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupFactory.java @@ -175,12 +175,21 @@ public interface SetupFactory extends EFactory CommandParameter createCommandParameter(); /** - * Returns a new object of class '<em>Eclipse Ini Task</em>'. + * Returns a new object of class '<em>Context Variable Task</em>'. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return a new object of class '<em>Eclipse Ini Task</em>'. + * <!-- end-user-doc --> + * @return a new object of class '<em>Context Variable Task</em>'. * @generated */ + ContextVariableTask createContextVariableTask(); + + /** + * Returns a new object of class '<em>Eclipse Ini Task</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Eclipse Ini Task</em>'. + * @generated + */ EclipseIniTask createEclipseIniTask(); /** diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupPackage.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupPackage.java index 71e37e94e6..5c763e21fc 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupPackage.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/SetupPackage.java @@ -1706,14 +1706,87 @@ public interface SetupPackage extends EPackage int COMMAND_PARAMETER_FEATURE_COUNT = 2; /** - * The meta object id for the '{@link org.eclipse.emf.cdo.releng.setup.SetupTaskScope <em>Task Scope</em>}' enum. + * The meta object id for the '{@link org.eclipse.emf.cdo.releng.setup.impl.ContextVariableTaskImpl <em>Context Variable Task</em>}' class. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.emf.cdo.releng.setup.SetupTaskScope - * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getSetupTaskScope() + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.releng.setup.impl.ContextVariableTaskImpl + * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getContextVariableTask() * @generated */ - int SETUP_TASK_SCOPE = 27; + int CONTEXT_VARIABLE_TASK = 27; + + /** + * The feature id for the '<em><b>Requirements</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CONTEXT_VARIABLE_TASK__REQUIREMENTS = SETUP_TASK__REQUIREMENTS; + + /** + * The feature id for the '<em><b>Restrictions</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CONTEXT_VARIABLE_TASK__RESTRICTIONS = SETUP_TASK__RESTRICTIONS; + + /** + * The feature id for the '<em><b>Scope</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CONTEXT_VARIABLE_TASK__SCOPE = SETUP_TASK__SCOPE; + + /** + * The feature id for the '<em><b>Excluded Triggers</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CONTEXT_VARIABLE_TASK__EXCLUDED_TRIGGERS = SETUP_TASK__EXCLUDED_TRIGGERS; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CONTEXT_VARIABLE_TASK__NAME = SETUP_TASK_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Value</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CONTEXT_VARIABLE_TASK__VALUE = SETUP_TASK_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Context Variable Task</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int CONTEXT_VARIABLE_TASK_FEATURE_COUNT = SETUP_TASK_FEATURE_COUNT + 2; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.releng.setup.SetupTaskScope <em>Task Scope</em>}' enum. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.releng.setup.SetupTaskScope + * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getSetupTaskScope() + * @generated + */ + int SETUP_TASK_SCOPE = 28; /** * The meta object id for the '{@link org.eclipse.emf.cdo.releng.setup.Trigger <em>Trigger</em>}' enum. @@ -1723,7 +1796,7 @@ public interface SetupPackage extends EPackage * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getTrigger() * @generated */ - int TRIGGER = 28; + int TRIGGER = 29; /** * The meta object id for the '<em>URI</em>' data type. @@ -1733,7 +1806,7 @@ public interface SetupPackage extends EPackage * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getURI() * @generated */ - int URI = 31; + int URI = 32; /** * The meta object id for the '<em>Exception</em>' data type. @@ -1743,7 +1816,7 @@ public interface SetupPackage extends EPackage * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getException() * @generated */ - int EXCEPTION = 30; + int EXCEPTION = 31; /** * The meta object id for the '<em>Trigger Set</em>' data type. @@ -1753,7 +1826,7 @@ public interface SetupPackage extends EPackage * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getTriggerSet() * @generated */ - int TRIGGER_SET = 29; + int TRIGGER_SET = 30; /** * Returns the meta object for class '{@link org.eclipse.emf.cdo.releng.setup.Configuration <em>Configuration</em>}'. @@ -2453,13 +2526,45 @@ public interface SetupPackage extends EPackage EAttribute getCommandParameter_Value(); /** - * Returns the meta object for class '{@link org.eclipse.emf.cdo.releng.setup.EclipseIniTask <em>Eclipse Ini Task</em>}'. + * Returns the meta object for class '{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask <em>Context Variable Task</em>}'. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @return the meta object for class '<em>Eclipse Ini Task</em>'. - * @see org.eclipse.emf.cdo.releng.setup.EclipseIniTask + * <!-- end-user-doc --> + * @return the meta object for class '<em>Context Variable Task</em>'. + * @see org.eclipse.emf.cdo.releng.setup.ContextVariableTask * @generated */ + EClass getContextVariableTask(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getName <em>Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Name</em>'. + * @see org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getName() + * @see #getContextVariableTask() + * @generated + */ + EAttribute getContextVariableTask_Name(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getValue <em>Value</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Value</em>'. + * @see org.eclipse.emf.cdo.releng.setup.ContextVariableTask#getValue() + * @see #getContextVariableTask() + * @generated + */ + EAttribute getContextVariableTask_Value(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.releng.setup.EclipseIniTask <em>Eclipse Ini Task</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Eclipse Ini Task</em>'. + * @see org.eclipse.emf.cdo.releng.setup.EclipseIniTask + * @generated + */ EClass getEclipseIniTask(); /** @@ -3352,13 +3457,39 @@ public interface SetupPackage extends EPackage EAttribute COMMAND_PARAMETER__VALUE = eINSTANCE.getCommandParameter_Value(); /** - * The meta object literal for the '{@link org.eclipse.emf.cdo.releng.setup.impl.EclipseIniTaskImpl <em>Eclipse Ini Task</em>}' class. + * The meta object literal for the '{@link org.eclipse.emf.cdo.releng.setup.impl.ContextVariableTaskImpl <em>Context Variable Task</em>}' class. * <!-- begin-user-doc --> - * <!-- end-user-doc --> - * @see org.eclipse.emf.cdo.releng.setup.impl.EclipseIniTaskImpl - * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getEclipseIniTask() + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.releng.setup.impl.ContextVariableTaskImpl + * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getContextVariableTask() * @generated */ + EClass CONTEXT_VARIABLE_TASK = eINSTANCE.getContextVariableTask(); + + /** + * The meta object literal for the '<em><b>Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute CONTEXT_VARIABLE_TASK__NAME = eINSTANCE.getContextVariableTask_Name(); + + /** + * The meta object literal for the '<em><b>Value</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute CONTEXT_VARIABLE_TASK__VALUE = eINSTANCE.getContextVariableTask_Value(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.releng.setup.impl.EclipseIniTaskImpl <em>Eclipse Ini Task</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.releng.setup.impl.EclipseIniTaskImpl + * @see org.eclipse.emf.cdo.releng.setup.impl.SetupPackageImpl#getEclipseIniTask() + * @generated + */ EClass ECLIPSE_INI_TASK = eINSTANCE.getEclipseIniTask(); /** diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/BuckminsterImportTaskImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/BuckminsterImportTaskImpl.java index 8a9be9e491..9bc9b9356e 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/BuckminsterImportTaskImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/BuckminsterImportTaskImpl.java @@ -178,10 +178,8 @@ public class BuckminsterImportTaskImpl extends SetupTaskImpl implements Buckmins String oldMspec = mspec; mspec = newMspec; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.BUCKMINSTER_IMPORT_TASK__MSPEC, oldMspec, mspec)); - } } /** @@ -204,10 +202,8 @@ public class BuckminsterImportTaskImpl extends SetupTaskImpl implements Buckmins String oldTargetPlatform = targetPlatform; targetPlatform = newTargetPlatform; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.BUCKMINSTER_IMPORT_TASK__TARGET_PLATFORM, oldTargetPlatform, targetPlatform)); - } } /** @@ -230,10 +226,8 @@ public class BuckminsterImportTaskImpl extends SetupTaskImpl implements Buckmins String oldBundlePool = bundlePool; bundlePool = newBundlePool; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.BUCKMINSTER_IMPORT_TASK__BUNDLE_POOL, oldBundlePool, bundlePool)); - } } /** @@ -332,9 +326,7 @@ public class BuckminsterImportTaskImpl extends SetupTaskImpl implements Buckmins public String toString() { if (eIsProxy()) - { return super.toString(); - } StringBuffer result = new StringBuffer(super.toString()); result.append(" (mspec: "); diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/CompoundSetupTaskImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/CompoundSetupTaskImpl.java index 438a5aecac..df04874cc5 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/CompoundSetupTaskImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/CompoundSetupTaskImpl.java @@ -129,9 +129,7 @@ public class CompoundSetupTaskImpl extends SetupTaskImpl implements CompoundSetu String oldName = name; name = newName; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.COMPOUND_SETUP_TASK__NAME, oldName, name)); - } } /** @@ -279,9 +277,7 @@ public class CompoundSetupTaskImpl extends SetupTaskImpl implements CompoundSetu public String toString() { if (eIsProxy()) - { return super.toString(); - } StringBuffer result = new StringBuffer(super.toString()); result.append(" (name: "); diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/ContextVariableTaskImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/ContextVariableTaskImpl.java new file mode 100644 index 0000000000..5acab72d08 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/ContextVariableTaskImpl.java @@ -0,0 +1,249 @@ +/** + */ +package org.eclipse.emf.cdo.releng.setup.impl; + +import org.eclipse.emf.cdo.releng.setup.ContextVariableTask; +import org.eclipse.emf.cdo.releng.setup.SetupPackage; +import org.eclipse.emf.cdo.releng.setup.SetupTaskContext; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.impl.ENotificationImpl; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Context Variable Task</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.releng.setup.impl.ContextVariableTaskImpl#getName <em>Name</em>}</li> + * <li>{@link org.eclipse.emf.cdo.releng.setup.impl.ContextVariableTaskImpl#getValue <em>Value</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public class ContextVariableTaskImpl extends SetupTaskImpl implements ContextVariableTask +{ + /** + * The default value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected static final String NAME_EDEFAULT = null; + + /** + * The cached value of the '{@link #getName() <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getName() + * @generated + * @ordered + */ + protected String name = NAME_EDEFAULT; + + /** + * The default value of the '{@link #getValue() <em>Value</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getValue() + * @generated + * @ordered + */ + protected static final String VALUE_EDEFAULT = null; + + /** + * The cached value of the '{@link #getValue() <em>Value</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #getValue() + * @generated + * @ordered + */ + protected String value = VALUE_EDEFAULT; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ContextVariableTaskImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SetupPackage.Literals.CONTEXT_VARIABLE_TASK; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() + { + return name; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) + { + String oldName = name; + name = newName; + if (eNotificationRequired()) + { + eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.CONTEXT_VARIABLE_TASK__NAME, oldName, name)); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getValue() + { + return value; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setValue(String newValue) + { + String oldValue = value; + value = newValue; + if (eNotificationRequired()) + { + eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.CONTEXT_VARIABLE_TASK__VALUE, oldValue, value)); + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) + { + switch (featureID) + { + case SetupPackage.CONTEXT_VARIABLE_TASK__NAME: + return getName(); + case SetupPackage.CONTEXT_VARIABLE_TASK__VALUE: + return getValue(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) + { + switch (featureID) + { + case SetupPackage.CONTEXT_VARIABLE_TASK__NAME: + setName((String)newValue); + return; + case SetupPackage.CONTEXT_VARIABLE_TASK__VALUE: + setValue((String)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void eUnset(int featureID) + { + switch (featureID) + { + case SetupPackage.CONTEXT_VARIABLE_TASK__NAME: + setName(NAME_EDEFAULT); + return; + case SetupPackage.CONTEXT_VARIABLE_TASK__VALUE: + setValue(VALUE_EDEFAULT); + return; + } + super.eUnset(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean eIsSet(int featureID) + { + switch (featureID) + { + case SetupPackage.CONTEXT_VARIABLE_TASK__NAME: + return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); + case SetupPackage.CONTEXT_VARIABLE_TASK__VALUE: + return VALUE_EDEFAULT == null ? value != null : !VALUE_EDEFAULT.equals(value); + } + return super.eIsSet(featureID); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String toString() + { + if (eIsProxy()) + { + return super.toString(); + } + + StringBuffer result = new StringBuffer(super.toString()); + result.append(" (name: "); + result.append(name); + result.append(", value: "); + result.append(value); + result.append(')'); + return result.toString(); + } + + public boolean isNeeded(SetupTaskContext context) throws Exception + { + String expandedValue = context.expandString(getValue()); + context.put(getName(), expandedValue); + return false; + } + + public void perform(SetupTaskContext context) throws Exception + { + } + +} // ContextVariableTaskImpl diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/EclipsePreferenceTaskImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/EclipsePreferenceTaskImpl.java index 090424fef9..68132cfd68 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/EclipsePreferenceTaskImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/EclipsePreferenceTaskImpl.java @@ -129,9 +129,7 @@ public class EclipsePreferenceTaskImpl extends SetupTaskImpl implements EclipseP String oldKey = key; key = newKey; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.ECLIPSE_PREFERENCE_TASK__KEY, oldKey, key)); - } } /** @@ -154,10 +152,8 @@ public class EclipsePreferenceTaskImpl extends SetupTaskImpl implements EclipseP String oldValue = value; value = newValue; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.ECLIPSE_PREFERENCE_TASK__VALUE, oldValue, value)); - } } /** @@ -245,9 +241,7 @@ public class EclipsePreferenceTaskImpl extends SetupTaskImpl implements EclipseP public String toString() { if (eIsProxy()) - { return super.toString(); - } StringBuffer result = new StringBuffer(super.toString()); result.append(" (key: "); diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/KeyBindingTaskImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/KeyBindingTaskImpl.java index ff58a0d263..b3ddfda5e1 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/KeyBindingTaskImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/KeyBindingTaskImpl.java @@ -234,9 +234,7 @@ public class KeyBindingTaskImpl extends SetupTaskImpl implements KeyBindingTask String oldScheme = scheme; scheme = newScheme; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.KEY_BINDING_TASK__SCHEME, oldScheme, scheme)); - } } /** @@ -259,9 +257,7 @@ public class KeyBindingTaskImpl extends SetupTaskImpl implements KeyBindingTask String oldContext = context; context = newContext; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.KEY_BINDING_TASK__CONTEXT, oldContext, context)); - } } /** @@ -284,10 +280,8 @@ public class KeyBindingTaskImpl extends SetupTaskImpl implements KeyBindingTask String oldPlatform = platform; platform = newPlatform; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.KEY_BINDING_TASK__PLATFORM, oldPlatform, platform)); - } } /** @@ -310,9 +304,7 @@ public class KeyBindingTaskImpl extends SetupTaskImpl implements KeyBindingTask String oldLocale = locale; locale = newLocale; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.KEY_BINDING_TASK__LOCALE, oldLocale, locale)); - } } /** @@ -335,9 +327,7 @@ public class KeyBindingTaskImpl extends SetupTaskImpl implements KeyBindingTask String oldKeys = keys; keys = newKeys; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.KEY_BINDING_TASK__KEYS, oldKeys, keys)); - } } /** @@ -360,9 +350,7 @@ public class KeyBindingTaskImpl extends SetupTaskImpl implements KeyBindingTask String oldCommand = command; command = newCommand; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.KEY_BINDING_TASK__COMMAND, oldCommand, command)); - } } /** @@ -533,9 +521,7 @@ public class KeyBindingTaskImpl extends SetupTaskImpl implements KeyBindingTask public String toString() { if (eIsProxy()) - { return super.toString(); - } StringBuffer result = new StringBuffer(super.toString()); result.append(" (scheme: "); diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupFactoryImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupFactoryImpl.java index 1f27cfec9a..8ec3465627 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupFactoryImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupFactoryImpl.java @@ -48,6 +48,7 @@ import org.eclipse.emf.ecore.plugin.EcorePlugin; import java.util.HashSet; import java.util.Set; +import org.eclipse.emf.cdo.releng.setup.*; /** * <!-- begin-user-doc --> @@ -147,6 +148,8 @@ public class SetupFactoryImpl extends EFactoryImpl implements SetupFactory return createKeyBindingTask(); case SetupPackage.COMMAND_PARAMETER: return createCommandParameter(); + case SetupPackage.CONTEXT_VARIABLE_TASK: + return createContextVariableTask(); default: throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); } @@ -380,9 +383,20 @@ public class SetupFactoryImpl extends EFactoryImpl implements SetupFactory /** * <!-- begin-user-doc --> - * <!-- end-user-doc --> + * <!-- end-user-doc --> * @generated */ + public ContextVariableTask createContextVariableTask() + { + ContextVariableTaskImpl contextVariableTask = new ContextVariableTaskImpl(); + return contextVariableTask; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ public EclipseIniTask createEclipseIniTask() { EclipseIniTaskImpl eclipseIniTask = new EclipseIniTaskImpl(); diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupImpl.java index 5637dc98c0..41a4f631db 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupImpl.java @@ -111,9 +111,7 @@ public class SetupImpl extends MinimalEObjectImpl.Container implements Setup if (branch != oldBranch) { if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.RESOLVE, SetupPackage.SETUP__BRANCH, oldBranch, branch)); - } } } return branch; @@ -139,9 +137,7 @@ public class SetupImpl extends MinimalEObjectImpl.Container implements Setup Branch oldBranch = branch; branch = newBranch; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.SETUP__BRANCH, oldBranch, branch)); - } } /** @@ -158,10 +154,8 @@ public class SetupImpl extends MinimalEObjectImpl.Container implements Setup if (eclipseVersion != oldEclipseVersion) { if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.RESOLVE, SetupPackage.SETUP__ECLIPSE_VERSION, oldEclipseVersion, eclipseVersion)); - } } } return eclipseVersion; @@ -187,10 +181,8 @@ public class SetupImpl extends MinimalEObjectImpl.Container implements Setup EclipseVersion oldEclipseVersion = eclipseVersion; eclipseVersion = newEclipseVersion; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.SETUP__ECLIPSE_VERSION, oldEclipseVersion, eclipseVersion)); - } } /** @@ -207,10 +199,8 @@ public class SetupImpl extends MinimalEObjectImpl.Container implements Setup if (preferences != oldPreferences) { if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.RESOLVE, SetupPackage.SETUP__PREFERENCES, oldPreferences, preferences)); - } } } return preferences; @@ -236,10 +226,8 @@ public class SetupImpl extends MinimalEObjectImpl.Container implements Setup Preferences oldPreferences = preferences; preferences = newPreferences; if (eNotificationRequired()) - { eNotify(new ENotificationImpl(this, Notification.SET, SetupPackage.SETUP__PREFERENCES, oldPreferences, preferences)); - } } /** @@ -307,21 +295,15 @@ public class SetupImpl extends MinimalEObjectImpl.Container implements Setup { case SetupPackage.SETUP__BRANCH: if (resolve) - { return getBranch(); - } return basicGetBranch(); case SetupPackage.SETUP__ECLIPSE_VERSION: if (resolve) - { return getEclipseVersion(); - } return basicGetEclipseVersion(); case SetupPackage.SETUP__PREFERENCES: if (resolve) - { return getPreferences(); - } return basicGetPreferences(); } return super.eGet(featureID, resolve, coreType); diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupPackageImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupPackageImpl.java index 1ea1c7e0a6..7b73583e53 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupPackageImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/SetupPackageImpl.java @@ -17,6 +17,7 @@ import org.eclipse.emf.cdo.releng.setup.CommandParameter; import org.eclipse.emf.cdo.releng.setup.CompoundSetupTask; import org.eclipse.emf.cdo.releng.setup.ConfigurableItem; import org.eclipse.emf.cdo.releng.setup.Configuration; +import org.eclipse.emf.cdo.releng.setup.ContextVariableTask; import org.eclipse.emf.cdo.releng.setup.EclipseIniTask; import org.eclipse.emf.cdo.releng.setup.EclipsePreferenceTask; import org.eclipse.emf.cdo.releng.setup.EclipseVersion; @@ -190,9 +191,16 @@ public class SetupPackageImpl extends EPackageImpl implements SetupPackage /** * <!-- begin-user-doc --> - * <!-- end-user-doc --> + * <!-- end-user-doc --> * @generated */ + private EClass contextVariableTaskEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ private EClass eclipseIniTaskEClass = null; /** @@ -1005,9 +1013,39 @@ public class SetupPackageImpl extends EPackageImpl implements SetupPackage /** * <!-- begin-user-doc --> - * <!-- end-user-doc --> + * <!-- end-user-doc --> * @generated */ + public EClass getContextVariableTask() + { + return contextVariableTaskEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getContextVariableTask_Name() + { + return (EAttribute)contextVariableTaskEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getContextVariableTask_Value() + { + return (EAttribute)contextVariableTaskEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ public EClass getEclipseIniTask() { return eclipseIniTaskEClass; @@ -1451,6 +1489,10 @@ public class SetupPackageImpl extends EPackageImpl implements SetupPackage createEAttribute(commandParameterEClass, COMMAND_PARAMETER__ID); createEAttribute(commandParameterEClass, COMMAND_PARAMETER__VALUE); + contextVariableTaskEClass = createEClass(CONTEXT_VARIABLE_TASK); + createEAttribute(contextVariableTaskEClass, CONTEXT_VARIABLE_TASK__NAME); + createEAttribute(contextVariableTaskEClass, CONTEXT_VARIABLE_TASK__VALUE); + // Create enums setupTaskScopeEEnum = createEEnum(SETUP_TASK_SCOPE); triggerEEnum = createEEnum(TRIGGER); @@ -1515,6 +1557,7 @@ public class SetupPackageImpl extends EPackageImpl implements SetupPackage resourceCopyTaskEClass.getESuperTypes().add(this.getSetupTask()); textModifyTaskEClass.getESuperTypes().add(this.getSetupTask()); keyBindingTaskEClass.getESuperTypes().add(this.getSetupTask()); + contextVariableTaskEClass.getESuperTypes().add(this.getSetupTask()); // Initialize classes and features; add operations and parameters initEClass(eclipseVersionEClass, EclipseVersion.class, "EclipseVersion", !IS_ABSTRACT, !IS_INTERFACE, @@ -1771,6 +1814,15 @@ public class SetupPackageImpl extends EPackageImpl implements SetupPackage initEAttribute(getCommandParameter_Value(), ecorePackage.getEString(), "value", null, 0, 1, CommandParameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEClass(contextVariableTaskEClass, ContextVariableTask.class, "ContextVariableTask", !IS_ABSTRACT, + !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getContextVariableTask_Name(), ecorePackage.getEString(), "name", null, 0, 1, + ContextVariableTask.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, + !IS_DERIVED, IS_ORDERED); + initEAttribute(getContextVariableTask_Value(), ecorePackage.getEString(), "value", null, 0, 1, + ContextVariableTask.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, + !IS_DERIVED, IS_ORDERED); + // Initialize enums and add enum literals initEEnum(setupTaskScopeEEnum, SetupTaskScope.class, "SetupTaskScope"); addEEnumLiteral(setupTaskScopeEEnum, SetupTaskScope.NONE); diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/StringVariableTaskImpl.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/StringVariableTaskImpl.java index be6ad8c1c0..149f544714 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/StringVariableTaskImpl.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/impl/StringVariableTaskImpl.java @@ -335,8 +335,6 @@ public class StringVariableTaskImpl extends SetupTaskImpl implements StringVaria cachedVariable = variable; expandedValue = context.expandString(getValue()); - context.put(getName(), expandedValue); - if (variable == null) { return true; diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupAdapterFactory.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupAdapterFactory.java index 32ca778a71..93a796143d 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupAdapterFactory.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupAdapterFactory.java @@ -10,6 +10,7 @@ */ package org.eclipse.emf.cdo.releng.setup.util; +import org.eclipse.emf.cdo.releng.setup.*; import org.eclipse.emf.cdo.releng.setup.ApiBaselineTask; import org.eclipse.emf.cdo.releng.setup.Branch; import org.eclipse.emf.cdo.releng.setup.BuckminsterImportTask; @@ -269,6 +270,12 @@ public class SetupAdapterFactory extends AdapterFactoryImpl } @Override + public Adapter caseContextVariableTask(ContextVariableTask object) + { + return createContextVariableTaskAdapter(); + } + + @Override public Adapter defaultCase(EObject object) { return createEObjectAdapter(); @@ -560,15 +567,30 @@ public class SetupAdapterFactory extends AdapterFactoryImpl } /** - * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.releng.setup.EclipseIniTask <em>Eclipse Ini Task</em>}'. + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.releng.setup.ContextVariableTask <em>Context Variable Task</em>}'. * <!-- begin-user-doc --> - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * <!-- end-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> * @return the new adapter. - * @see org.eclipse.emf.cdo.releng.setup.EclipseIniTask + * @see org.eclipse.emf.cdo.releng.setup.ContextVariableTask * @generated */ + public Adapter createContextVariableTaskAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.releng.setup.EclipseIniTask <em>Eclipse Ini Task</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.releng.setup.EclipseIniTask + * @generated + */ public Adapter createEclipseIniTaskAdapter() { return null; diff --git a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupSwitch.java b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupSwitch.java index 47d21fdde4..e48a9a604f 100644 --- a/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupSwitch.java +++ b/plugins/org.eclipse.emf.cdo.releng.setup/src/org/eclipse/emf/cdo/releng/setup/util/SetupSwitch.java @@ -43,6 +43,7 @@ import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.EObject; import java.util.List; +import org.eclipse.emf.cdo.releng.setup.*; /** * <!-- begin-user-doc --> @@ -383,6 +384,16 @@ public class SetupSwitch<T> result = defaultCase(theEObject); return result; } + case SetupPackage.CONTEXT_VARIABLE_TASK: + { + ContextVariableTask contextVariableTask = (ContextVariableTask)theEObject; + T result = caseContextVariableTask(contextVariableTask); + if (result == null) + result = caseSetupTask(contextVariableTask); + if (result == null) + result = defaultCase(theEObject); + return result; + } default: return defaultCase(theEObject); } @@ -725,16 +736,32 @@ public class SetupSwitch<T> } /** - * Returns the result of interpreting the object as an instance of '<em>Eclipse Ini Task</em>'. + * Returns the result of interpreting the object as an instance of '<em>Context Variable Task</em>'. * <!-- begin-user-doc --> - * This implementation returns null; - * returning a non-null result will terminate the switch. - * <!-- end-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> * @param object the target of the switch. - * @return the result of interpreting the object as an instance of '<em>Eclipse Ini Task</em>'. + * @return the result of interpreting the object as an instance of '<em>Context Variable Task</em>'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated */ + public T caseContextVariableTask(ContextVariableTask object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Eclipse Ini Task</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Eclipse Ini Task</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ public T caseEclipseIniTask(EclipseIniTask object) { return null; |