/** * {@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.obeonetwork.dsl.cinematic.flow.parts.SubflowStatePropertiesEditionPart#initSubflow(EObjectFlatComboSettings) */ public void initSubflow(EObjectFlatComboSettings settings) { subflow.setInput(settings); if (current != null) { subflow.setSelection(new StructuredSelection(settings.getValue())); } boolean eefElementEditorReadOnlyState = isReadOnly(FlowViewsRepository.SubflowState.Properties.subflow); if (eefElementEditorReadOnlyState && subflow.isEnabled()) { subflow.setEnabled(false); subflow.setToolTipText(FlowMessages.SubflowState_ReadOnly); } else if (!eefElementEditorReadOnlyState && !subflow.isEnabled()) { subflow.setEnabled(true); } }
/** * {@inheritDoc} * * @see * net.certware.sacm.SACM.Evidence.parts.HasRoleInPropertiesEditionPart#initOrganization(EObjectFlatComboSettings) */ public void initOrganization(EObjectFlatComboSettings settings) { organization.setInput(settings); if (current != null) { organization.setSelection(new StructuredSelection(settings.getValue())); } boolean eefElementEditorReadOnlyState = isReadOnly(EvidenceViewsRepository.HasRoleIn.Properties.organization); if (eefElementEditorReadOnlyState && organization.isEnabled()) { organization.setEnabled(false); organization.setToolTipText(EvidenceMessages.HasRoleIn_ReadOnly); } else if (!eefElementEditorReadOnlyState && !organization.isEnabled()) { organization.setEnabled(true); } }
/** * {@inheritDoc} * * @see * org.obeonetwork.dsl.database.parts.ForeignKeyPropertiesEditionPart#initTarget(EObjectFlatComboSettings) */ public void initTarget(EObjectFlatComboSettings settings) { target.setInput(settings); if (current != null) { target.setSelection(new StructuredSelection(settings.getValue())); } boolean eefElementEditorReadOnlyState = isReadOnly(DatabaseViewsRepository.ForeignKey.Properties.target); if (eefElementEditorReadOnlyState && target.isEnabled()) { target.setEnabled(false); target.setToolTipText(DatabaseMessages.ForeignKey_ReadOnly); } else if (!eefElementEditorReadOnlyState && !target.isEnabled()) { target.setEnabled(true); } }
/** * {@inheritDoc} * * @see * org.obeonetwork.dsl.cinematic.view.parts.ViewElementPropertiesEditionPart#initType(EObjectFlatComboSettings) */ public void initType(EObjectFlatComboSettings settings) { type.setInput(settings); if (current != null) { type.setSelection(new StructuredSelection(settings.getValue())); } boolean eefElementEditorReadOnlyState = isReadOnly(ViewViewsRepository.ViewElement.Properties.type); if (eefElementEditorReadOnlyState && type.isEnabled()) { type.setEnabled(false); type.setToolTipText(ViewMessages.ViewElement_ReadOnly); } else if (!eefElementEditorReadOnlyState && !type.isEnabled()) { type.setEnabled(true); } }
/** * {@inheritDoc} * * @see * org.obeonetwork.graal.parts.TransitionPropertiesEditionPart#initSource(EObjectFlatComboSettings) */ public void initSource(EObjectFlatComboSettings settings) { source.setInput(settings); if (current != null) { source.setSelection(new StructuredSelection(settings.getValue())); } boolean eefElementEditorReadOnlyState = isReadOnly(GraalViewsRepository.Transition.Properties.source); if (eefElementEditorReadOnlyState && source.isEnabled()) { source.setEnabled(false); source.setToolTipText(GraalMessages.Transition_ReadOnly); } else if (!eefElementEditorReadOnlyState && !source.isEnabled()) { source.setEnabled(true); } }
/** * {@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())); } }
/** * {@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.obeonetwork.dsl.uml2.properties.uml.parts.CreationEventPropertiesEditionPart#initTemplateParameter(EObjectFlatComboSettings) */ public void initTemplateParameter(EObjectFlatComboSettings settings) { templateParameter.setInput(settings); if (current != null) { templateParameter.setSelection(new StructuredSelection(settings.getValue())); } }
/** * {@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.obeonetwork.dsl.typeslibrary.parts.SimpleNamedTypePropertiesEditionPart#initType(EObjectFlatComboSettings) */ public void initType(EObjectFlatComboSettings settings) { type.setInput(settings); if (current != null) { type.setSelection(new StructuredSelection(settings.getValue())); } }
/** * {@inheritDoc} * * @see ewe.parts.ProjectPropertiesEditionPart#initDefaultTarget(EObjectFlatComboSettings) */ public void initDefaultTarget(EObjectFlatComboSettings settings) { defaultTarget.setInput(settings); if (current != null) { defaultTarget.setSelection(new StructuredSelection(settings.getValue())); } }
/** * {@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) { MeansThat meansThat = (MeansThat) semanticObject; if (EvidenceViewsRepository.MeansThat.Properties.id == event.getAffectedEditor()) { meansThat.setId( (java.lang.String) EEFConverterUtil.createFromString( SACMPackage.Literals.STRING, (String) event.getNewValue())); } if (EvidenceViewsRepository.MeansThat.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.MeansThat.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.MeansThat.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.MeansThat.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.MeansThat.Properties.attribute == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, attributeSettings, 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) { attributeSettings.removeFromReference((EObject) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.MOVE) { attributeSettings.move(event.getNewIndex(), (EvidenceAttribute) event.getNewValue()); } } if (EvidenceViewsRepository.MeansThat.Properties.subject == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { subjectSettings.setToReference((EvidenceElement) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, subjectSettings, 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 (EvidenceViewsRepository.MeansThat.Properties.meaning == event.getAffectedEditor()) { if (event.getKind() == PropertiesEditionEvent.SET) { meaningSettings.setToReference((FormalAssertion) event.getNewValue()); } else if (event.getKind() == PropertiesEditionEvent.ADD) { EReferencePropertiesEditionContext context = new EReferencePropertiesEditionContext( editingContext, this, meaningSettings, 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(); } } } } }