Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Lorenzo2017-01-21 17:03:28 +0000
committervincent lorenzo2017-01-23 12:47:27 +0000
commit3075bb0452dd395fdd6598f6dc03c3229232279f (patch)
tree16967e9affbe5cfa4af497dc48871eec2d07f853 /extraplugins/migration
parent327e635669b302bcaff775c8f31aa97ddee49144 (diff)
downloadorg.eclipse.papyrus-3075bb0452dd395fdd6598f6dc03c3229232279f.tar.gz
org.eclipse.papyrus-3075bb0452dd395fdd6598f6dc03c3229232279f.tar.xz
org.eclipse.papyrus-3075bb0452dd395fdd6598f6dc03c3229232279f.zip
Bug 510862: [Importer][Rhapsody] In some case, the type of the ports is not set during the QVTo transformation
Change-Id: Ib2cc198a2089da8a6d7c50d7264718bce61368c6 Signed-off-by: Vincent Lorenzo <vincent.lorenzo@cea.fr>
Diffstat (limited to 'extraplugins/migration')
-rw-r--r--extraplugins/migration/rhapsody/org.eclipse.papyrus.migration.rhapsody/transform/Rhapsody2PapyrusSemanticElements.qvto8
1 files changed, 6 insertions, 2 deletions
diff --git a/extraplugins/migration/rhapsody/org.eclipse.papyrus.migration.rhapsody/transform/Rhapsody2PapyrusSemanticElements.qvto b/extraplugins/migration/rhapsody/org.eclipse.papyrus.migration.rhapsody/transform/Rhapsody2PapyrusSemanticElements.qvto
index 3fee6c63f65..b095b57787c 100644
--- a/extraplugins/migration/rhapsody/org.eclipse.papyrus.migration.rhapsody/transform/Rhapsody2PapyrusSemanticElements.qvto
+++ b/extraplugins/migration/rhapsody/org.eclipse.papyrus.migration.rhapsody/transform/Rhapsody2PapyrusSemanticElements.qvto
@@ -230,7 +230,7 @@ mapping umlrhapsody::IType::iTypeToUMLElement() : uml::Element
umlrhapsody::IType::toUMLDatatype,
umlrhapsody::IType::toUMLInstanceSpecification,
umlrhapsody::IType::toUMLEnumeration,
- umlrhapsody::IType::iTypeToUMLClass,
+ umlrhapsody::IType::iTypeToUMLClass, //TODO : merge me with the existing other way to create a class
umlrhapsody::IType::iTypeToDefault
//don't forget to call the query mapToBasicType for created element instance of uml::TemplateableElement
{}
@@ -689,7 +689,11 @@ mapping umlrhapsody::IRelation::iRelationToSysMLPort(): uml::Port when {self.isR
var sysPort:umlrhapsody::ISysMLPort:=self.oclAsType(ISysMLPort);
name:= sysPort.name.replaceAll("\"","");
if (not sysPort.otherClass.oclIsUndefined()){
- type := sysPort.otherClass [IType]->any(true).oclAsType(IType).map iTypeToUMLElement().oclAsType(Type);
+ if(sysPort.otherClass.oclIsKindOf(IType)){
+ type := sysPort.otherClass.oclAsType(IType).map iTypeToUMLElement().oclAsType(Type);
+ }elif(sysPort.otherClass.oclIsKindOf(IClass)){
+ type := sysPort.otherClass.oclAsType(IClass).map toUMLElement().oclAsType(Type);
+ }
};
aggregation:=AggregationKind::composite;
isConjugated:=sysPort.isConjugated();

Back to the top