Bug 286222

Summary: Incomplete type checking for collections in assignments
Product: [Modeling] QVTo Reporter: Sergey Boyko <serg.boyko2011>
Component: EngineAssignee: Sergey Boyko <serg.boyko2011>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: dvorak.radek
Version: 2.0   
Target Milestone: 2.0.1   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Sergey Boyko CLA 2009-08-11 07:39:28 EDT
Start new platform with QVTO installed. Create 'SimpleUML to RDB' sample project.

Add the following mapping to the end of the script:

mapping UML::Class::class2viewColumns(targetClass: UML::Class) : OrderedSet(RDB::view::ViewColumn) {
    init {
    	var v := object RDB::view::ViewColumn {};
        result := self.map dataType2columns(targetClass)->
            union(self.map generalizations2columns(targetClass))->asOrderedSet()
    }   
}

No error is reported.
However it faces two problems.
1. Creation of abstract type 'RDB::view::ViewColumn' should be prohibited
2. Assignment of collection(RDB::TableColumn) to collection(RDB::view::ViewColumn) is also invalid
Comment 1 Sergey Boyko CLA 2009-08-14 05:31:27 EDT
Fixed in part of collection assignment checking.
Committed to HEAD and R2_0_maintenance branch.
Comment 2 Sergey Boyko CLA 2009-08-26 07:07:30 EDT
Abstract type instantiation checking is separate bug.