On-demand Instant Reverse Engineering
Instant Reverse is enhanced to support Java 1.5 syntax. With this enhancement, Java source and class files, Java Archive (JAR) containing Java class files and ZIP file containing Java source, which contains Java 1.5 syntax can all be reverse engineering to UML class models. In addition, on-demand reverse engineering is introduced to address the performance issue arises when reverse engineering a huge code base. With this option, class model(s) would not be reversed from code until it is being used.
Adding Java Resources for Instant Reverse
Select
Tools >
Instant Reverse >
Java... from the main menu.
OR Click on the
Instant Reverse... button

on the toolbar and then select
Java... from the drop-down menu.
The
Instant Reverse Options dialog box is displayed. From the dialog, you can add JAR files, folders of Java class files, ZIP files and folders of Java source files for reverse engineering.
You can add several Java Resources for reverse engineering.
If necessary, select a resource and check
Reverse source on demand to indicate that the resource will not be reversed until it is being used. With the
Reverse source on demand option unchecked, concrete models will be reversed from the resource to the project when the Instant Reverse process starts.
For the resources checked with
Reverse source on demand, they will be added to the
Java Resources folder under the
Class Repository as pointers to the underlying source file(s).
Reverse engineer on selected Java Resources
After Java Resources are added, they are ready to become class models in the project. With the enhanced Instant Reverse feature, there are three ways for you to create class models from Java Resources. They are Reverse to Class Repository, Reverse to Diagram, and Reverse by drag-and-drop.
Reverse to Class Repository
From the
Class Repository tree, select the Java Resources that you want the class models to be reversed from (multiple selection is allowed). Right-click on the selection and select
Reverse “Resources” to >
Class Repository from the popup menu to reverse the selected resources to the class repository.
The
Smart Reverse dialog box will appear to show the reverse progress of the selected resource (in this case the java.util package from
JDK 1.5 source zip file and the sample java sources files of JTreeTable).
When the progress reaches 100%, the class models are added to the
Class Repository tree.
Reverse to Diagram
From the
Class Repository tree, select the Java Resources that you want the class models to be reversed from (multiple selection is allowed). Right-click on the selection and select
Reverse “src” to >
New Class Diagram from the popup menu to reverse the selected resources to the class repository and create a new class diagram for them.
The
Smart Reverse dialog box will appear to show the reverse progress of the selected resource (in this case the sample java sources files on saxpath).
After the reverse engineer process is completed, it will create diagram for the reversed models. The
Create Diagram dialog box will appear to show the progress.
A class diagram is automatically created. The selected class models that have just been reversed from the Java source files are added to the class diagram with the appropriate layout.
Reverse by drag-and-drop
Create a new
Class Diagram, drag the selected resources from the
Class Repository tree and drop it onto the diagram.
The class models of selected resources will be formed, and the shapes of the class models are placed on the diagram.
Related Articles
Resources
-
-
-
Chapter 7 Instant Reverse - This chapter guides you through the process of reverse engineering different kinds of sources or binary files (Java source, Java classes, C++ Source, JDBC, .NET binaries, Hibernate mapping files, CORBA IDL, Ada 9x) into VP-UML.
-
-
-