This procedure is correct for the C++ add-in. For the Ansi C++, it is slightly different, take a look at: ---------------------------------------------------------------------------- ---------- QUESTION: I would like to generate more than one class to a header/body file using the ANSI C++ add-in to Rose. Can this be done? ANSWER: To do this, set the HeaderSourceFile property for both/all classes to the same file and do the same for the BodySourceFile property as well. This can be done by either by manually editing the properties or by using the anc_setsourcefile.ebs script found at: ftp://ftp.rational.com/exchange/outgoing/ANSI_C++/ The script will need to be launched from a menu. The following lines can be added to the cpp.mnu file that is found in the Rational\Rose\ansi c++ directory: Menu Tools { Separator Menu "ANSI C++ Scripts" { option "Set Source File (Selected Classes..." { enable %selected_items:empty:false RoseScript $SCRIPT_PATH\anc_setsourcefile.ebs } } Separator ... The $SCRIPT_PATH referred to here is the patmapped location of the anc_setsourcefile.ebs on your hard disk. You could also use an absolute path instead of a pathmapped path if desired. BE SURE TO SAVE AND BACKUP YOUR MODEL BEFORE YOU RUN THIS SCRIPT. For more information, contact Rational Software Technical Support. ---------------------------------------------------------------------------- ---------- Hanane Rose TSE -----Original Message----- From: Styve, Arne [mailto:[EMAIL PROTECTED]] Sent: Monday, May 21, 2001 1:00 PM To: Frank Adcock; 'Rose (E-mail)' Subject: RE: (ROSE) Multiple class ANSI C++ Generation into single file Yes, with ANSI C++ it's no problem. In Component View you have to create a component for each file you want to code-generate, i.e. one file of type Package Body (or equivalent), which when set to the C++ language, will result in the .CPP-file to be generated, and one component stereotyped to Package Specification, which when set to C++ language, will result in the .HPP (or .H)-file to be generated. Then specify which classes you want to be generated in each of these component by ticking/assigning the classes from the 'Realizes'-tab in the Component Specification Dialog. Remember to to this assignment for both components (both .cpp and .h). When generating code, all classes assigned to the component representing the .CPP-file will be generated in a .CPP-file with a filename equivalent to the name of the component. Hope this answers your question :-) Regards Arne Styve > -----Original Message----- > From: Frank Adcock [mailto:[EMAIL PROTECTED]] > Sent: Monday, May 21, 2001 12:04 AM > To: 'Rose (E-mail)' > Subject: (ROSE) Multiple class ANSI C++ Generation into single file > > > > Is it possible to have multiple classes generated into the > one source file. > This would be particularly useful in terms of including exception code > within the same file as the classes generating the exceptions > and much more > user friendly for the library users. > > Regards > > -------------------------------------------------------------- > -------------- > ---------------- > Frank Adcock Tel: +61 7 3880 2586 > Whitesmiths Australia Pty Ltd Fax: +61 7 3880 2133 > www.whitesmiths.com.au Email: > [EMAIL PROTECTED] > -------------------------------------------------------------- > -------------- > ---------------- > > ************************************************************** > ********** > * Rose Forum is a public venue for ideas and discussions. > * For technical support, visit http://www.rational.com/support > * > * Admin.Subscription Requests: [EMAIL PROTECTED] > * Archive of messages: http://www.rational.com/products/rose/usergroups/rose_forum.jtmpl * Other Requests: [EMAIL PROTECTED] * * To unsubscribe from the list, please send email * * To: [EMAIL PROTECTED] * Subject:<BLANK> * Body: unsubscribe rose_forum * ************************************************************************* This email, its content and any attachments is PRIVATE AND CONFIDENTIAL to TANDBERG Television. If received in error please notify the sender and destroy the original message and attachments. ************************************************************************ * Rose Forum is a public venue for ideas and discussions. * For technical support, visit http://www.rational.com/support * * Admin.Subscription Requests: [EMAIL PROTECTED] * Archive of messages: http://www.rational.com/products/rose/usergroups/rose_forum.jtmpl * Other Requests: [EMAIL PROTECTED] * * To unsubscribe from the list, please send email * * To: [EMAIL PROTECTED] * Subject:<BLANK> * Body: unsubscribe rose_forum * ************************************************************************* ************************************************************************ * Rose Forum is a public venue for ideas and discussions. * For technical support, visit http://www.rational.com/support * * Admin.Subscription Requests: [EMAIL PROTECTED] * Archive of messages: http://www.rational.com/products/rose/usergroups/rose_forum.jtmpl * Other Requests: [EMAIL PROTECTED] * * To unsubscribe from the list, please send email * * To: [EMAIL PROTECTED] * Subject:<BLANK> * Body: unsubscribe rose_forum * *************************************************************************
RE: (ROSE) Multiple class ANSI C++ Generation into single file
Rational Technical Support (Europe) Tue, 22 May 2001 05:35:09 -0700
- RE: (ROSE) Multiple class ANSI C++ Gen... Styve, Arne
- RE: (ROSE) Multiple class ANSI C+... Rational Technical Support (Europe)
- RE: (ROSE) Multiple class ANSI C+... Mathieu Girard (Montreuil)
