|
@@ -74,7 +74,6 @@ public class OperationDefinitionItemProvider
|
|
|
super.getPropertyDescriptors(object);
|
|
super.getPropertyDescriptors(object);
|
|
|
|
|
|
|
|
addTypePropertyDescriptor(object);
|
|
addTypePropertyDescriptor(object);
|
|
|
- addParamTypesPropertyDescriptor(object);
|
|
|
|
|
}
|
|
}
|
|
|
return itemPropertyDescriptors;
|
|
return itemPropertyDescriptors;
|
|
|
}
|
|
}
|
|
@@ -102,29 +101,6 @@ public class OperationDefinitionItemProvider
|
|
|
null));
|
|
null));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- /**
|
|
|
|
|
- * This adds a property descriptor for the Param Types feature.
|
|
|
|
|
- * <!-- begin-user-doc -->
|
|
|
|
|
- * <!-- end-user-doc -->
|
|
|
|
|
- * @generated
|
|
|
|
|
- */
|
|
|
|
|
- protected void addParamTypesPropertyDescriptor(Object object)
|
|
|
|
|
- {
|
|
|
|
|
- itemPropertyDescriptors.add
|
|
|
|
|
- (createItemPropertyDescriptor
|
|
|
|
|
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
|
|
|
|
|
- getResourceLocator(),
|
|
|
|
|
- getString("_UI_OperationDefinition_paramTypes_feature"),
|
|
|
|
|
- getString("_UI_PropertyDescriptor_description", "_UI_OperationDefinition_paramTypes_feature", "_UI_OperationDefinition_type"),
|
|
|
|
|
- StextPackage.Literals.OPERATION_DEFINITION__PARAM_TYPES,
|
|
|
|
|
- true,
|
|
|
|
|
- false,
|
|
|
|
|
- true,
|
|
|
|
|
- null,
|
|
|
|
|
- null,
|
|
|
|
|
- null));
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
/**
|
|
/**
|
|
|
* This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
|
|
* This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
|
|
|
* {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
|
|
* {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
|
|
@@ -140,6 +116,7 @@ public class OperationDefinitionItemProvider
|
|
|
{
|
|
{
|
|
|
super.getChildrenFeatures(object);
|
|
super.getChildrenFeatures(object);
|
|
|
childrenFeatures.add(TypesPackage.Literals.OPERATION__PARAMETERS);
|
|
childrenFeatures.add(TypesPackage.Literals.OPERATION__PARAMETERS);
|
|
|
|
|
+ childrenFeatures.add(StextPackage.Literals.OPERATION_DEFINITION__PARAMS);
|
|
|
}
|
|
}
|
|
|
return childrenFeatures;
|
|
return childrenFeatures;
|
|
|
}
|
|
}
|
|
@@ -200,6 +177,7 @@ public class OperationDefinitionItemProvider
|
|
|
switch (notification.getFeatureID(OperationDefinition.class))
|
|
switch (notification.getFeatureID(OperationDefinition.class))
|
|
|
{
|
|
{
|
|
|
case StextPackage.OPERATION_DEFINITION__PARAMETERS:
|
|
case StextPackage.OPERATION_DEFINITION__PARAMETERS:
|
|
|
|
|
+ case StextPackage.OPERATION_DEFINITION__PARAMS:
|
|
|
fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
|
|
fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
@@ -222,6 +200,36 @@ public class OperationDefinitionItemProvider
|
|
|
(createChildParameter
|
|
(createChildParameter
|
|
|
(TypesPackage.Literals.OPERATION__PARAMETERS,
|
|
(TypesPackage.Literals.OPERATION__PARAMETERS,
|
|
|
TypesFactory.eINSTANCE.createParameter()));
|
|
TypesFactory.eINSTANCE.createParameter()));
|
|
|
|
|
+
|
|
|
|
|
+ newChildDescriptors.add
|
|
|
|
|
+ (createChildParameter
|
|
|
|
|
+ (StextPackage.Literals.OPERATION_DEFINITION__PARAMS,
|
|
|
|
|
+ TypesFactory.eINSTANCE.createParameter()));
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ /**
|
|
|
|
|
+ * This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}.
|
|
|
|
|
+ * <!-- begin-user-doc -->
|
|
|
|
|
+ * <!-- end-user-doc -->
|
|
|
|
|
+ * @generated
|
|
|
|
|
+ */
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public String getCreateChildText(Object owner, Object feature, Object child, Collection<?> selection)
|
|
|
|
|
+ {
|
|
|
|
|
+ Object childFeature = feature;
|
|
|
|
|
+ Object childObject = child;
|
|
|
|
|
+
|
|
|
|
|
+ boolean qualify =
|
|
|
|
|
+ childFeature == TypesPackage.Literals.OPERATION__PARAMETERS ||
|
|
|
|
|
+ childFeature == StextPackage.Literals.OPERATION_DEFINITION__PARAMS;
|
|
|
|
|
+
|
|
|
|
|
+ if (qualify)
|
|
|
|
|
+ {
|
|
|
|
|
+ return getString
|
|
|
|
|
+ ("_UI_CreateChild_text2",
|
|
|
|
|
+ new Object[] { getTypeText(childObject), getFeatureText(childFeature), getTypeText(owner) });
|
|
|
|
|
+ }
|
|
|
|
|
+ return super.getCreateChildText(owner, feature, child, selection);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|