Skip to main content



      Home
Home » Modeling » UML2 » Redefinition code generation issue
Redefinition code generation issue [message #626839] Wed, 30 July 2008 20:39
Eclipse UserFriend
I am wondering if the correct code is generated for a model like the
following.

I have classes A and B, A has property b of type B.
A' and B' are subclasses of A and B, respectively.
A' has a property b of type B', so this b redefines property b in A.

I would expect to see a method public B' getB() {...} in the code for A'
(which would be fine in Java 6, and compliance level is set to 6.0 in the
genmodel). However, the generated method returns an object of type B. Is
this a bug or did I miss something?

If I rename the property in A' to c, then I get: public B' getC() {...} (and
also public B getB() that returns the same value)

Thanks,
Lutz


  • Attachment: n.png
    (Size: 3.26KB, Downloaded 197 times)
Previous Topic:Instrumenting field class on Operation?
Next Topic:Support for multi-language documentation
Goto Forum:
  


Current Time: Tue Jul 01 03:33:23 EDT 2025

Powered by FUDForum. Page generated in 0.07982 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top