use of org.obeonetwork.dsl.soa.Operation in project InformationSystem by ObeoNetwork.
the class OperationOperationPropertiesEditionComponent method initPart.
/**
* {@inheritDoc}
*
* @see org.eclipse.emf.eef.runtime.api.component.IPropertiesEditionComponent#initPart(java.lang.Object, int, org.eclipse.emf.ecore.EObject,
* org.eclipse.emf.ecore.resource.ResourceSet)
*/
public void initPart(Object key, int kind, EObject elt, ResourceSet allResource) {
setInitializing(true);
if (editingPart != null && key == partKey) {
editingPart.setContext(elt, allResource);
final Operation operation = (Operation) elt;
final OperationPropertiesEditionPart operationPart = (OperationPropertiesEditionPart) editingPart;
// init values
if (isAccessible(SoaViewsRepository.Operation.Properties.name))
operationPart.setName(EEFConverterUtil.convertToString(EcorePackage.Literals.ESTRING, operation.getName()));
if (isAccessible(SoaViewsRepository.Operation.Properties.kind)) {
operationPart.initKind(EEFUtils.choiceOfValues(operation, SoaPackage.eINSTANCE.getOperation_Kind()), operation.getKind());
}
if (isAccessible(SoaViewsRepository.Operation.Properties.public_)) {
operationPart.setPublic_(operation.isPublic());
}
if (isAccessible(SoaViewsRepository.Operation.Properties.description))
operationPart.setDescription(EcoreUtil.convertToString(EcorePackage.Literals.ESTRING, operation.getDescription()));
// init filters
// init values for referenced views
// init filters for referenced views
}
setInitializing(false);
}
use of org.obeonetwork.dsl.soa.Operation in project InformationSystem by ObeoNetwork.
the class ParameterItemProvider method getImage.
/**
* This returns Parameter.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated NOT
*/
@Override
public Object getImage(Object object) {
if (object instanceof Parameter) {
Parameter parameter = (Parameter) object;
EObject container = parameter.eContainer();
if (container instanceof Operation) {
Operation operation = (Operation) container;
if (operation.getInput().contains(parameter)) {
return overlayImage(object, getResourceLocator().getImage("full/obj16/Input"));
} else if (operation.getOutput().contains(parameter)) {
return overlayImage(object, getResourceLocator().getImage("full/obj16/Output"));
} else {
return overlayImage(object, getResourceLocator().getImage("full/obj16/Fault"));
}
}
}
return overlayImage(object, getResourceLocator().getImage("full/obj16/Parameter"));
}
Aggregations