Permalink
Browse files

[#125] Missing scheduling restriction for disjoint execution

  • Loading branch information...
RobertHilbrich committed Jul 10, 2018
1 parent 0c4bcf7 commit eac3b967d9fd2f9bb0347e5b077495df06eb46a0
Showing with 355 additions and 27 deletions.
  1. BIN ...edit/icons/full/ctool16/CreateAssistModel_schedulingRestrictions_RestrictionDisjointExecution.gif
  2. BIN ch.hilbri.assist.model.edit/icons/full/obj16/RestrictionDisjointExecution.gif
  3. +1 −0 ch.hilbri.assist.model.edit/plugin.properties
  4. +5 −0 ch.hilbri.assist.model.edit/src/ch/hilbri/assist/model/provider/AssistModelItemProvider.java
  5. +24 −0 ch.hilbri.assist.model.edit/src/ch/hilbri/assist/model/provider/ModelItemProviderAdapterFactory.java
  6. +94 −0 ...sist.model.edit/src/ch/hilbri/assist/model/provider/RestrictionDisjointExecutionItemProvider.java
  7. +3 −1 ch.hilbri.assist.model/model/ASSIST-Model.xcore
  8. +9 −0 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/ModelFactory.java
  9. +78 −21 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/ModelPackage.java
  10. +17 −0 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/RestrictionDisjointExecution.java
  11. +12 −0 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/impl/ModelFactoryImpl.java
  12. +22 −0 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/impl/ModelPackageImpl.java
  13. +37 −0 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/impl/RestrictionDisjointExecutionImpl.java
  14. +19 −0 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/util/ModelAdapterFactory.java
  15. +24 −0 ch.hilbri.assist.model/src-gen/ch/hilbri/assist/model/util/ModelSwitch.java
  16. +1 −1 ch.hilbri.assist.scheduling.dsl.tests/META-INF/MANIFEST.MF
  17. +1 −1 ch.hilbri.assist.scheduling.dsl.ui/META-INF/MANIFEST.MF
  18. +2 −2 ch.hilbri.assist.scheduling.dsl/META-INF/MANIFEST.MF
  19. +6 −1 ch.hilbri.assist.scheduling.dsl/src/ch/hilbri/assist/scheduling/dsl/SchedulingDsl.xtext
@@ -493,3 +493,4 @@ _UI_FeatureRequirement_name_feature = Name
_UI_AssistModel___feature =
_UI_HardwareElement_getHardwareArchitectureLevel_feature = Get Hardware Architecture Level
_UI_HardwareElement_getHardwareLevel_feature = Get Hardware Level
_UI_RestrictionDisjointExecution_type = Restriction Disjoint Execution
@@ -303,6 +303,11 @@ protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors
(ModelPackage.Literals.ASSIST_MODEL__SCHEDULING_RESTRICTIONS,
ModelFactory.eINSTANCE.createRestrictionStartAfterOtherStarted()));
newChildDescriptors.add
(createChildParameter
(ModelPackage.Literals.ASSIST_MODEL__SCHEDULING_RESTRICTIONS,
ModelFactory.eINSTANCE.createRestrictionDisjointExecution()));
newChildDescriptors.add
(createChildParameter
(ModelPackage.Literals.ASSIST_MODEL__APPLICATION_ALTERNATIVES,
@@ -761,6 +761,29 @@ public Adapter createRestrictionStartAfterOtherStartedAdapter() {
return restrictionStartAfterOtherStartedItemProvider;
}
/**
* This keeps track of the one adapter used for all {@link ch.hilbri.assist.model.RestrictionDisjointExecution} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected RestrictionDisjointExecutionItemProvider restrictionDisjointExecutionItemProvider;
/**
* This creates an adapter for a {@link ch.hilbri.assist.model.RestrictionDisjointExecution}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public Adapter createRestrictionDisjointExecutionAdapter() {
if (restrictionDisjointExecutionItemProvider == null) {
restrictionDisjointExecutionItemProvider = new RestrictionDisjointExecutionItemProvider(this);
}
return restrictionDisjointExecutionItemProvider;
}
/**
* This keeps track of the one adapter used for all {@link ch.hilbri.assist.model.CustomProperty} instances.
* <!-- begin-user-doc -->
@@ -1143,6 +1166,7 @@ public void dispose() {
if (restrictionFinishAtTheSameTimeItemProvider != null) restrictionFinishAtTheSameTimeItemProvider.dispose();
if (restrictionStartAfterOtherFinishedItemProvider != null) restrictionStartAfterOtherFinishedItemProvider.dispose();
if (restrictionStartAfterOtherStartedItemProvider != null) restrictionStartAfterOtherStartedItemProvider.dispose();
if (restrictionDisjointExecutionItemProvider != null) restrictionDisjointExecutionItemProvider.dispose();
if (customPropertyItemProvider != null) customPropertyItemProvider.dispose();
if (customIntPropertyItemProvider != null) customIntPropertyItemProvider.dispose();
if (customStringPropertyItemProvider != null) customStringPropertyItemProvider.dispose();
@@ -0,0 +1,94 @@
/**
*/
package ch.hilbri.assist.model.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.edit.provider.IItemPropertyDescriptor;
/**
* This is the item provider adapter for a {@link ch.hilbri.assist.model.RestrictionDisjointExecution} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public class RestrictionDisjointExecutionItemProvider extends SimpleRelationItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public RestrictionDisjointExecutionItemProvider(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);
}
return itemPropertyDescriptors;
}
/**
* This returns RestrictionDisjointExecution.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public Object getImage(Object object) {
return overlayImage(object, getResourceLocator().getImage("full/obj16/RestrictionDisjointExecution"));
}
/**
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
@Override
public String getText(Object object) {
return getString("_UI_RestrictionDisjointExecution_type");
}
/**
* 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);
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);
}
}
@@ -286,7 +286,7 @@ class ComplexRelation extends SchedulingRestriction {
int delay
}
// Conrete relations:
// Concrete relations:
// Task1, Task2, ... start at the same time;
class RestrictionStartAtTheSameTime extends SimpleRelation {}
@@ -301,6 +301,8 @@ class RestrictionStartAfterOtherFinished extends ComplexRelation {}
// Task3, Task4, ... start after Task1 has started (with delay of min X);
class RestrictionStartAfterOtherStarted extends ComplexRelation {}
// Task1, Task2, ... require disjoint execution;
class RestrictionDisjointExecution extends SimpleRelation {}
/* ********************************************** */
/* METRIC PARAMETERS */
@@ -291,6 +291,15 @@
*/
RestrictionStartAfterOtherStarted createRestrictionStartAfterOtherStarted();
/**
* Returns a new object of class '<em>Restriction Disjoint Execution</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @return a new object of class '<em>Restriction Disjoint Execution</em>'.
* @generated
*/
RestrictionDisjointExecution createRestrictionDisjointExecution();
/**
* Returns a new object of class '<em>Custom Property</em>'.
* <!-- begin-user-doc -->
Oops, something went wrong.

0 comments on commit eac3b96

Please sign in to comment.