/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { State state = (State) semanticObject; if (StatemachineViewsRepository.State.Properties.name == event.getAffectedEditor()) { state.setName( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (StatemachineViewsRepository.State.Properties.actions == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof Command) { actionsSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { actionsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { actionsSettings.move(event.getNewIndex(), (Command) event.getNewValue()); } } if (StatemachineViewsRepository.State.Properties.transitions == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, transitionsSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { transitionsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { transitionsSettings.move(event.getNewIndex(), (Transition) event.getNewValue()); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ @Override public void updateSemanticModel(final IPropertiesEditionEvent event) { final ForeignKeyElement foreignKeyElement = (ForeignKeyElement) this.semanticObject; if (DatabaseViewsRepository.ForeignKeyElement.Properties.comments == event.getAffectedEditor()) { foreignKeyElement.setComments( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (DatabaseViewsRepository.ForeignKeyElement.Properties.fKColumn == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { this.fkColumnSettings.setToReference(event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { final Column eObject = DatabaseFactory.eINSTANCE.createColumn(); final EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( this.editingContext, this, eObject, this.editingContext.getAdapterFactory()); final PropertiesEditingProvider provider = (PropertiesEditingProvider) this.editingContext .getAdapterFactory() .adapt(eObject, PropertiesEditingProvider.class); if (provider != null) { final PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); } } this.fkColumnSettings.setToReference(eObject); } } if (DatabaseViewsRepository.ForeignKeyElement.Properties.pKColumn == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { this.pkColumnSettings.setToReference(event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { final Column eObject = DatabaseFactory.eINSTANCE.createColumn(); final EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( this.editingContext, this, eObject, this.editingContext.getAdapterFactory()); final PropertiesEditingProvider provider = (PropertiesEditingProvider) this.editingContext .getAdapterFactory() .adapt(eObject, PropertiesEditingProvider.class); if (provider != null) { final PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); } } this.pkColumnSettings.setToReference(eObject); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { ProcessComponent processComponent = (ProcessComponent) semanticObject; if (SpemViewsRepository.ProcessComponent.Properties.name == event.getAffectedEditor()) { processComponent.setName( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.eINSTANCE.getEString(), (String) event.getNewValue())); } if (SpemViewsRepository.ProcessComponent.Properties.ownedProcessMember == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, ownedProcessMemberSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { ownedProcessMemberSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { ownedProcessMemberSettings.move( event.getNewIndex(), (ProcessPackageableElement) event.getNewValue()); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ @Override public void updateSemanticModel(final IPropertiesEditionEvent event) { ItemizedList itemizedList = (ItemizedList) semanticObject; if (DocbookViewsRepository.ItemizedList.Properties.mark == event.getAffectedEditor()) { itemizedList.setMark( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (DocbookViewsRepository.ItemizedList.Properties.listitem == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, listitemSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { listitemSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { listitemSettings.move(event.getNewIndex(), (ListItem) event.getNewValue()); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { DomainClass domainClass = (DomainClass) semanticObject; if (GraalViewsRepository.DomainClass.Properties.name == event.getAffectedEditor()) { domainClass.setName( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (GraalViewsRepository.DomainClass.Properties.superType == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { superTypeSettings.setToReference((StructuredType) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, superTypeSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } } if (GraalViewsRepository.DomainClass.Properties.description == event.getAffectedEditor()) { domainClass.setDescription( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { ViewReference viewReference = (ViewReference) semanticObject; if (ViewsViewsRepository.ViewReference.Properties.name == event.getAffectedEditor()) { viewReference.setName( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (ViewsViewsRepository.ViewReference.Properties.referencedView == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { viewSettings.setToReference((ViewElement) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, viewSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { PropertiesEditionElement propertiesEditionElement = (PropertiesEditionElement) semanticObject; if (ComponentsViewsRepository.PropertiesEditionElement.Properties.name == event.getAffectedEditor()) { propertiesEditionElement.setName( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (ComponentsViewsRepository.PropertiesEditionElement.Binding.views == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof ElementEditor) { viewsSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { viewsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { viewsSettings.move(event.getNewIndex(), (ElementEditor) event.getNewValue()); } } if (ComponentsViewsRepository.PropertiesEditionElement.Binding.model == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { modelSettings.setToReference((EStructuralFeature) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, modelSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } } if (ComponentsViewsRepository.PropertiesEditionElement.Properties.helpID == event.getAffectedEditor()) { propertiesEditionElement.setHelpID( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } }
protected void editClientDependency(EObject element) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( propertiesEditionComponent.getEditingContext(), propertiesEditionComponent, element, adapterFactory); PropertiesEditingProvider provider = (PropertiesEditingProvider) adapterFactory.adapt(element, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); clientDependency.refresh(); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { Refutes refutes = (Refutes) semanticObject; if (EvidenceViewsRepository.Notes.Properties.taggedValue == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, taggedValueSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { taggedValueSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { taggedValueSettings.move(event.getNewIndex(), (TaggedValue) event.getNewValue()); } } if (EvidenceViewsRepository.Notes.Properties.annotation == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, annotationSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { annotationSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { annotationSettings.move(event.getNewIndex(), (Annotation) event.getNewValue()); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { InputPin inputPin = (InputPin) semanticObject; if (UmlViewsRepository.InputPin.Properties.name == event.getAffectedEditor()) { inputPin.setName( (java.lang.String) EEFConverterUtil.createFromString( UMLPackage.eINSTANCE.getString(), (String) event.getNewValue())); } if (UmlViewsRepository.InputPin.Properties.visibility == event.getAffectedEditor()) { inputPin.setVisibility((VisibilityKind) event.getNewValue()); } if (UmlViewsRepository.InputPin.Properties.clientDependency == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof Dependency) { clientDependencySettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { clientDependencySettings.removeFromReference((EObject) event.getNewValue()); } } if (UmlViewsRepository.InputPin.Properties.isLeaf == event.getAffectedEditor()) { inputPin.setIsLeaf((Boolean) event.getNewValue()); } if (UmlViewsRepository.InputPin.Properties.inStructuredNode == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { inStructuredNodeSettings.setToReference((StructuredActivityNode) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { StructuredActivityNode eObject = UMLFactory.eINSTANCE.createStructuredActivityNode(); EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, eObject, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); } } inStructuredNodeSettings.setToReference(eObject); } } if (UmlViewsRepository.InputPin.Properties.activity == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { activitySettings.setToReference((Activity) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { Activity eObject = UMLFactory.eINSTANCE.createActivity(); EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, eObject, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); } } activitySettings.setToReference(eObject); } } if (UmlViewsRepository.InputPin.Properties.outgoing == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof ActivityEdge) { outgoingSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { outgoingSettings.removeFromReference((EObject) event.getNewValue()); } } if (UmlViewsRepository.InputPin.Properties.incoming == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof ActivityEdge) { incomingSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { incomingSettings.removeFromReference((EObject) event.getNewValue()); } } if (UmlViewsRepository.InputPin.Properties.inPartition == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof ActivityPartition) { inPartitionSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { inPartitionSettings.removeFromReference((EObject) event.getNewValue()); } } if (UmlViewsRepository.InputPin.Properties.inInterruptibleRegion == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof InterruptibleActivityRegion) { inInterruptibleRegionSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { inInterruptibleRegionSettings.removeFromReference((EObject) event.getNewValue()); } } if (UmlViewsRepository.InputPin.Properties.redefinedNode == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof ActivityNode) { redefinedNodeSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { redefinedNodeSettings.removeFromReference((EObject) event.getNewValue()); } } if (UmlViewsRepository.InputPin.Properties.type == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { typeSettings.setToReference((Type) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, typeSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } } if (UmlViewsRepository.InputPin.Properties.ordering == event.getAffectedEditor()) { inputPin.setOrdering((ObjectNodeOrderingKind) event.getNewValue()); } if (UmlViewsRepository.InputPin.Properties.isControlType == event.getAffectedEditor()) { inputPin.setIsControlType((Boolean) event.getNewValue()); } if (UmlViewsRepository.InputPin.Properties.inState == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof State) { inStateSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { inStateSettings.removeFromReference((EObject) event.getNewValue()); } } if (UmlViewsRepository.InputPin.Properties.selection == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { selectionSettings.setToReference((Behavior) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, selectionSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } } if (UmlViewsRepository.InputPin.Properties.isOrdered == event.getAffectedEditor()) { inputPin.setIsOrdered((Boolean) event.getNewValue()); } if (UmlViewsRepository.InputPin.Properties.isUnique == event.getAffectedEditor()) { inputPin.setIsUnique((Boolean) event.getNewValue()); } if (UmlViewsRepository.InputPin.Properties.isControl == event.getAffectedEditor()) { inputPin.setIsControl((Boolean) event.getNewValue()); } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { Transition transition = (Transition) semanticObject; if (StatemachineViewsRepository.Transition.Properties.description == event.getAffectedEditor()) { transition.setDescription( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (StatemachineViewsRepository.Transition.Properties.keywords == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { transition.getKeywords().clear(); transition.getKeywords().addAll(((EList) event.getNewValue())); } } if (StatemachineViewsRepository.Transition.Properties.guard == event.getAffectedEditor()) { transition.setGuard( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (StatemachineViewsRepository.Transition.Properties.from == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { fromSettings.setToReference((AbstractState) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, fromSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } } if (StatemachineViewsRepository.Transition.Properties.to == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { toSettings.setToReference((AbstractState) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, toSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { Solution solution = (Solution) semanticObject; if (GsnViewsRepository.Solution.Properties.identifier == event.getAffectedEditor()) { solution.setIdentifier( (java.lang.String) EEFConverterUtil.createFromString( ArmPackage.eINSTANCE.getString(), (String) event.getNewValue())); } if (GsnViewsRepository.Solution.Properties.description == event.getAffectedEditor()) { solution.setDescription( (java.lang.String) EEFConverterUtil.createFromString( ArmPackage.eINSTANCE.getString(), (String) event.getNewValue())); } if (GsnViewsRepository.Solution.Properties.content == event.getAffectedEditor()) { solution.setContent( (java.lang.String) EEFConverterUtil.createFromString( ArmPackage.eINSTANCE.getString(), (String) event.getNewValue())); } if (GsnViewsRepository.Solution.Properties.isTagged == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, isTaggedSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { isTaggedSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { isTaggedSettings.move(event.getNewIndex(), (TaggedValue) event.getNewValue()); } } if (GsnViewsRepository.Solution.Properties.target == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof ModelElement) { targetSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { targetSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { targetSettings.move(event.getNewIndex(), (ModelElement) event.getNewValue()); } } if (GsnViewsRepository.Solution.Properties.source == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof ModelElement) { sourceSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { sourceSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { sourceSettings.move(event.getNewIndex(), (ModelElement) event.getNewValue()); } } if (GsnViewsRepository.Solution.Properties.solutionEvidence == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, solutionEvidenceSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { solutionEvidenceSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { solutionEvidenceSettings.move(event.getNewIndex(), (Evidence) event.getNewValue()); } } if (GsnViewsRepository.Solution.Properties.solutionContexts == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, solutionContextsSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { solutionContextsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { solutionContextsSettings.move(event.getNewIndex(), (Context) event.getNewValue()); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { LinkEndDestructionData linkEndDestructionData = (LinkEndDestructionData) semanticObject; if (UmlViewsRepository.LinkEndDestructionData.Properties.value == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { valueSettings.setToReference((InputPin) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { InputPin eObject = UMLFactory.eINSTANCE.createInputPin(); EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, eObject, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); } } valueSettings.setToReference(eObject); } } if (UmlViewsRepository.LinkEndDestructionData.Properties.end == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { endSettings.setToReference((Property) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { Property eObject = UMLFactory.eINSTANCE.createProperty(); EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, eObject, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); } } endSettings.setToReference(eObject); } } if (UmlViewsRepository.LinkEndDestructionData.Properties.isDestroyDuplicates == event.getAffectedEditor()) { linkEndDestructionData.setIsDestroyDuplicates((Boolean) event.getNewValue()); } if (UmlViewsRepository.LinkEndDestructionData.Properties.destroyAt == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { destroyAtSettings.setToReference((InputPin) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { InputPin eObject = UMLFactory.eINSTANCE.createInputPin(); EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, eObject, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext.getAdapterFactory().adapt(eObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy != null) { policy.execute(); } } destroyAtSettings.setToReference(eObject); } } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ @Override public void updateSemanticModel(final IPropertiesEditionEvent event) { final Task task = (Task) this.semanticObject; if (GraalViewsRepository.Task.Properties.description == event.getAffectedEditor()) { task.setDescription( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (GraalViewsRepository.Task.Properties.subActivities == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { final EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( this.editingContext, this, this.subActivitiesSettings, this.editingContext.getAdapterFactory()); final PropertiesEditingProvider provider = (PropertiesEditingProvider) this.editingContext .getAdapterFactory() .adapt(this.semanticObject, PropertiesEditingProvider.class); if (provider != null) { final PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { final EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( this.editingContext, this, (EObject) event.getNewValue(), this.editingContext.getAdapterFactory()); final PropertiesEditingProvider provider = (PropertiesEditingProvider) this.editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { final PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { this.subActivitiesSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { this.subActivitiesSettings.move(event.getNewIndex(), (Activity) event.getNewValue()); } } if (GraalViewsRepository.Task.Properties.actors == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof Actor) { this.actorsSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { this.actorsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { this.actorsSettings.move(event.getNewIndex(), (Actor) event.getNewValue()); } } if (GraalViewsRepository.Task.Properties.id == event.getAffectedEditor()) { task.setId( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (GraalViewsRepository.Task.Properties.name == event.getAffectedEditor()) { task.setName( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (GraalViewsRepository.Task.Properties.uses == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { if (event.getNewValue() instanceof Task) { this.usesSettings.addToReference((EObject) event.getNewValue()); } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { this.usesSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { this.usesSettings.move(event.getNewIndex(), (Task) event.getNewValue()); } } if (GraalViewsRepository.Task.Properties.preconditions == event.getAffectedEditor()) { task.setPreconditions( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } if (GraalViewsRepository.Task.Properties.postconditions == event.getAffectedEditor()) { task.setPostconditions( (java.lang.String) EEFConverterUtil.createFromString( EcorePackage.Literals.ESTRING, (String) event.getNewValue())); } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { Consistency consistency = (Consistency) semanticObject; if (EvidenceViewsRepository.Consistency.Properties.id == event.getAffectedEditor()) { consistency.setId( (java.lang.String) EEFConverterUtil.createFromString( SACMPackage.Literals.STRING, (String) event.getNewValue())); } if (EvidenceViewsRepository.Consistency.Properties.timing == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, timingSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { timingSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { timingSettings.move(event.getNewIndex(), (TimingProperty) event.getNewValue()); } } if (EvidenceViewsRepository.Consistency.Properties.custody == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, custodySettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { custodySettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { custodySettings.move(event.getNewIndex(), (CustodyProperty) event.getNewValue()); } } if (EvidenceViewsRepository.Consistency.Properties.provenance == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, provenanceSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { provenanceSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { provenanceSettings.move(event.getNewIndex(), (Provenance) event.getNewValue()); } } if (EvidenceViewsRepository.Consistency.Properties.event == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, eventSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { eventSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { eventSettings.move(event.getNewIndex(), (EvidenceEvent) event.getNewValue()); } } if (EvidenceViewsRepository.Consistency.Properties.value == event.getAffectedEditor()) { consistency.setValue((ConsistencyLevel) event.getNewValue()); } }
/** * {@inheritDoc} * * @see * org.eclipse.emf.eef.runtime.impl.components.StandardPropertiesEditionComponent#updateSemanticModel(org.eclipse.emf.eef.runtime.api.notify.IPropertiesEditionEvent) */ public void updateSemanticModel(final IPropertiesEditionEvent event) { Goal goal = (Goal) semanticObject; if (GsnViewsRepository.Goal.Properties.identifier == event.getAffectedEditor()) { goal.setIdentifier( (java.lang.String) EEFConverterUtil.createFromString( ArmPackage.eINSTANCE.getString(), (String) event.getNewValue())); } if (GsnViewsRepository.Goal.Properties.description == event.getAffectedEditor()) { goal.setDescription( (java.lang.String) EEFConverterUtil.createFromString( ArmPackage.eINSTANCE.getString(), (String) event.getNewValue())); } if (GsnViewsRepository.Goal.Properties.content == event.getAffectedEditor()) { goal.setContent( (java.lang.String) EEFConverterUtil.createFromString( ArmPackage.eINSTANCE.getString(), (String) event.getNewValue())); } if (GsnViewsRepository.Goal.Properties.isTagged == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, isTaggedSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { isTaggedSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { isTaggedSettings.move(event.getNewIndex(), (TaggedValue) event.getNewValue()); } } if (GsnViewsRepository.Goal.Properties.assumed == event.getAffectedEditor()) { goal.setAssumed((Boolean) event.getNewValue()); } if (GsnViewsRepository.Goal.Properties.toBeSupported == event.getAffectedEditor()) { goal.setToBeSupported((Boolean) event.getNewValue()); } if (GsnViewsRepository.Goal.Properties.subGoals == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, subGoalsSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { subGoalsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { subGoalsSettings.move(event.getNewIndex(), (Goal) event.getNewValue()); } } if (GsnViewsRepository.Goal.Properties.strategies == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, strategiesSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { strategiesSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { strategiesSettings.move(event.getNewIndex(), (Strategy) event.getNewValue()); } } if (GsnViewsRepository.Goal.Properties.goalContexts == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, goalContextsSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { goalContextsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { goalContextsSettings.move(event.getNewIndex(), (Context) event.getNewValue()); } } if (GsnViewsRepository.Goal.Properties.assumptions == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, assumptionsSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { assumptionsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { assumptionsSettings.move(event.getNewIndex(), (Assumption) event.getNewValue()); } } if (GsnViewsRepository.Goal.Properties.goalSolutions == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, goalSolutionsSettings, editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt(semanticObject, PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy policy = provider.getPolicy(context); if (policy instanceof CreateEditingPolicy) { policy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.EDIT) { EObjectPropertiesEditionContext context = new EObjectPropertiesEditionContext( editingContext, this, (EObject) event.getNewValue(), editingContext.getAdapterFactory()); PropertiesEditingProvider provider = (PropertiesEditingProvider) editingContext .getAdapterFactory() .adapt((EObject) event.getNewValue(), PropertiesEditingProvider.class); if (provider != null) { PropertiesEditingPolicy editionPolicy = provider.getPolicy(context); if (editionPolicy != null) { editionPolicy.execute(); } } } else if (event.getKind() == PropertiesEditionEvent.REMOVE) { goalSolutionsSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { goalSolutionsSettings.move(event.getNewIndex(), (Solution) event.getNewValue()); } } }