You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to sparx-enterprise-archite...@googlegroups.com
Hello all, It seems trivial, but I have apparently forgotten how to get EA to show constructor/destructors on class diagrams. I actually have a model stub that shows them, but all my new classes do not, even though they show any other operations and attributes I create for the class. So three questions: 1. How to get constructor displayed on class diagrams. 2. Why would EA not show them by default? 3. Where could I have found the answer to this in the so-called 'Help' documentation.
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to sparx-enterprise-archite...@googlegroups.com
Hi There is an option the settings for code engineering that specifies if a constructor/destructor is generated when code for the class is generated. Reverse engineering will the of course add the operations to you class
[original message]
rgsheehan
unread,
Jul 12, 2012, 9:02:00 AM7/12/12
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to sparx-enterprise-archite...@googlegroups.com
SomersetGraham,
Yes, the approach you suggested works. Thank you. Not sure what Sparx is thinking here. It sure seems to me to be a convoluted, roundabout, non-intuitive approach to what would arguably be a primary usage of the tool.
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to sparx-enterprise-archite...@googlegroups.com
Well the code generation only makes a default constructor which is not always what you want You can define more constructors using the operations page
[original message]
Schollii
unread,
Oct 18, 2017, 4:23:00 PM10/18/17
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Sparx Enterprise Architect General
I agree, but not every OO language has a constructor. For example Python (supported by EA) has initializers which are similar but not identical to C++ constructors. Initializers in Python are intuitively an operation (self exists and gets extended with attributes). It is not so intuitive to think of constructors as operations but really they are: they are just a way to setup the initial state of the instance, and there can be many (overloads) of them (which emphasizes that an operation is the right way to think about a constructor).