[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools.uml2] Re: Is Feature Refinement supported ?

Kenn,

We look forward to your article!
No wonder you have little extra time,
with all there's to do,
and all our questions,
that you answer so timely!

But, in the meanwhile, a simple list of artefacts
(mmelements, UML2 elements, templates, ...)
where feature refinement is contemplated
a few symbols to "grep" for,
a little paraphrasing of the logic used,
would surely save us (to me, at least) a score of hours in looking around !

Too late for a beer and a dinner for a bribe at Esslingen,
 - I'm kidding -  ... but the offer stands !   :-)

Thanks a lot, in any case

Antonio Carrasco Valero
Model Driven Development ltd.



"Kenn Hussey" <khussey@xxxxxxxxxx> wrote in message 
news:ehnmqu$cmb$1@xxxxxxxxxxxxxxxxxxxx
> Lutz,
>
> Sorry, documentation on this aspect of UML2 is non-existent a this point; 
> others have had some success by playing with the various options and 
> seeing what happens (perhaps they'll share their experiences). I've been 
> trying to find time to write an article about it, but alas... however, I 
> hope to propose a tutorial/talk on extending UML2 at EclipseCon 2007, so 
> one way or another documentation should become available at some point...
>
> Kenn
>
> "Lutz Wrage" <lw_mailme_00@xxxxxxxxx> wrote in message 
> news:ehni91$bn7$1@xxxxxxxxxxxxxxxxxxxx
>> Kenn,
>>
>> is there any documentation available that describes these extensions? I 
>> couldn't find any - apart from the source code, of course :-)
>>
>> Thanks,
>> Lutz
>>
>> Kenn Hussey wrote:
>>> Antonio,
>>>
>>> Feature refinement (redefinition and subsetting) is supported by the 
>>> UML2 code generator extension...
>>>
>>> Kenn
>>>
>>> "Antonio Carrasco Valero" <acv@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> wrote in 
>>> message news:ehlcbp$kmk$1@xxxxxxxxxxxxxxxxxxxx
>>>> Hi Ed!
>>>>
>>>> Should we consider thes limitation,
>>>> of eCore not allowing redefinition of features in subclasses,
>>>> as something to resolve in the future ?
>>>>
>>>> This seriously impairs the ability to reuse Eclipse UML implementation 
>>>> in DSLs.
>>>>
>>>> I believe that that, in the very honest goal
>>>> of keeping EMF codegen straightforward,
>>>> those honestly interested in the reuse of Eclipse UML in their DSLs,
>>>> will be seriously discouraged to do so.
>>>>
>>>> This limitation forces to do all kinds of nasty hacks in the 
>>>> metamodels,
>>>> that´s why it is used all over the UML2 specification
>>>> (and why package merge and UML flattening is possible).
>>>>
>>>> Other ways of constraining, apart from subclassing UML,
>>>> still leave a metamodel that is exactly like the original, unrefined 
>>>> one,
>>>> when inspected reflectively.
>>>> This amounts the same as creating Profiles of UML
>>>> - as many are so intelligently doint, given the obstacles to derive 
>>>> DSLs from UML.
>>>>
>>>> Cheers,
>>>> Antonio Carrasco Valero
>>>> Model Driven Development ltd.
>>>>
>>>>
>>>>
>>>>
>>>> "Ed Merks" <merks@xxxxxxxxxx> wrote in message 
>>>> news:ehkt0k$ehc$1@xxxxxxxxxxxxxxxxxxxx
>>>>> Antonio,
>>>>>
>>>>> This is possible in UML2 but not in Ecore.  The UML2 Ecore  importer 
>>>>> will create new features (with a different name)s for such a cases. 
>>>>> Narrowing the multiplicity isn't even possible with Java , i.e., 
>>>>> List<X> getX can't be overridden with X getX(), and narrowing the type 
>>>>> would only be possible for single valued features in Java 5.0, i.e., X 
>>>>> getX() can be overridden by Y getX() if Y inherits from X, and isn't 
>>>>> possible for multi-valued features in Java 5.0 because there is no 
>>>>> inheritance relation between List<X> and List<Y> regardless of the 
>>>>> inheritance relation between X and Y, i.e., List getX can be 
>>>>> overridden by List getX but List<X> getX cannot be overridden by 
>>>>> List<Y> getX. It's usually best to consider such refinements to be 
>>>>> constraints rather than to expect the API itself to morph since Java 
>>>>> is not completely capable of expressing this.
>>>>>
>>>>>
>>>>> Antonio Carrasco Valero wrote:
>>>>>> Hi !
>>>>>> Is it possible to refine features in subclasses ?
>>>>>> i.e, define in a sub-EClass,
>>>>>> an EReference feature that re-defines the referenced type
>>>>>> to an specialization of the type referenced by the supertype,
>>>>>> or that narrows multiplicity from 1..n to 1..1, ...
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>
>>>
>