Quick Links
C# Reverse Program Users Guide
The C# Reverse Program was created as a sample program by using Astah API. With this program, you can generate Astah models from C# Source Code. Please read the License Agreement before you start using this program.
- System Environment
- Supported C# items
- Steps for importing C# Source Code
- Configure the Astah C# Reverse program - Config.properties
- Auto-Create Class Diagram
- Compile Sample Application
Doxygen
To use this program, you need to have Doxygen, which is free. Because this program requires an XML file that is generated by Doxygen.
About Support Service
This program is provided as a sample of Astah API, so Change Vision, Inc. shall not provide technical support for any problems during using this C# Reverse Program.
System Environment
Both OS and Java Running Environment need to meet the same system requirements to run Astah UML or Astah Professional. This program has been tested on Windows only.
- Astah Professional, Astah UML 6.0 or later
Astah Professional(Astah UML) Install Folder\lib\commons-digester.jar(version 1.5) - Java Running Environment (Applicable Java version for Astah Professional(Astah UML) is required)
- Doxygen 1.7.1 (doxygen-1.7.1-setup.exe), Doxygen Main Site or Download Doxygen
For details about Doxygen, please refer to the license or documents they provide
Supported C# items
This program reverses all Classes, Attributes and Operations including their specified definitions.
Pointers would be reversed as a class with * in its name. This specification may be changed in the future version.
See Supported C# items for details.
Steps for importing C# Source Code
- Download Doxygen
- Download doxygen-1.7.1-setup.exe at Doxygen Download Page.
- Install and Launch
- Double-click the doxygen-1.7.1-setup.exe and install.
- Select Start menu - "doxygen" - "doxywizard" to launch Doxygen.
- Set up Doxygen
- Click "Save" button on the [Doxygen GUI Frontend] dialog and save the setting.
- Specify the Doxygen Working Directory on the [Doxygen GUI Frontend] at step3.
- Importing Source code by Doxygen
- Click "Start" button on the [Doxygen GUI Frontend] at step4 to generate XML.
- The message "*** Doxygen has finished" appears when it completes successfully
- Generate Astah models from the XML
- To generate Astah models, use the Astah Professional(Astah UML) Install folder\api\sample\sample_doxygen_c_plus\run.bat
i.e. Generate the XMI file (C:\doxygen_xml) to Astah models (C:\doxygen_xml\converted.asta)run.bat C:\doxygen_xml C:\doxygen_xml\converted.asta
- To generate Astah models, use the Astah Professional(Astah UML) Install folder\api\sample\sample_doxygen_c_plus\run.bat
| Destination directory | Do not use the following symbols. If it includes any of them, the reverse program may not work properly. &, <, >, * or @ |
| Select the desired extraction mode | Select "Documented entities only" |
| Select Programming language to optimize the result for | Select "Optimize for C# output" or "Optimize for C#/CLI output" |
| Select the output format(s) to generate | Select "XML" if you are using Doxygen 1.5.6, 1.5.7.1, 1.5.8, 1.7.0 or 1.7.1 Select both "HTML" and "XML" if you are using Doxygen 1.5.7 (Checking on "XML" only does not export XML in Doxygen1.5.7 properly) |
| INPUT_ENCODING | Specify the correct Character encoding that is used for the Source code |
Configure the Astah C# Reverse program - Config.properties
You are able to customize the C# reverse program by modifying the following file.
Astah Professional(Astah UML) install folder\api\sample\sample_doxygen_c_plus\doxygen_cplus\Config.properties
| jude_cplus_types_for_attribute | You can specify how you want to reverse the Property, as either Class's Attribute or Association. Properties are reversed as Associations by default. However if you define types in the Config.properties, you can reverse properties with the defined types as Class's Attributes. (i.e.) BrickOut::Form1,BrickOut::Form2 |
Auto-Create Class Diagram
You are able to generate Class diagrams with the Source Code you imported just by selecting [Auto Create Class Diagram/Detailed Class Diagram] menu from the Pop-up menu of Project, Package, Subsystem, Model or Classes in the Structure Tree.
[Tips] Auto-Create Class Diagram (Astah User Community)
Compile sample application
If you have altered the source code of this program, you need to compile before rerunning. To compile, double click the following file. Astah professional (Astah UML)
install folder\api\sample\sample_doxygen_c_sharp\compile.bat





![Subscribe to our blog! [Subscribe]](/resources/images/main/rss.png)




