Tool Mentors > Rational Rose Tool Set > Rational Rose Tool Mentors > Reverse-Engineering Code Using Rational Rose
This tool mentor describes Rational Rose's ability to reverse-engineer various types of elements into a Rose model, including elements as varied as language source and binary code, Type Libraries, Web-based elements, XML DTDs, and database schemas.
Related Rational Unified Process information:
Reverse engineering is the process of examining an existing resource, recovering information about its design, then using that information to generate or update a model representing the project's logical structure. It enables you to reuse elements common to more than one model or system. It also enables you to iteratively develop (round trip) a system through analysis and design in Rational Rose, generating source code from the model, developing the source, then reverse engineering the source back into a Rose model.
The following Rational Rose add-ins provide reverse engineering features:
Rational Rose Visual C++ enables you to reverse-engineer Visual C++ source code. Its features include:
Being tightly integrated with the Microsoft Visual Basic 6.0 environment, the Rational Rose Visual Basic Language Support Add-in enables you to update and subsequently evolve a Rose model from changes in the Visual Basic source code. The extensible and customizable dialog-based tools guide you smoothly through the process of updating the model when the source code is changed.
The Type Library Importer in Rational Rose enables you to import a type library of a COM component (.dll, .exe, .ocx, .olb, and .tlb files) into a Rose model. The type library is represented as a component and as a logical package in the model. The logical package contains the type library items that are defined by the type information of the imported COM component, such as coclasses, interfaces, dispinterfaces, and so forth. Each item is represented by a class.
By importing type libraries into a model, you can show how classes in the model use, implement, or depend upon classes and interfaces in other COM components, regardless of their implementation language. Features of the Type Library Importer include:
The way you use a type library varies from one programming language to another. For more information, see the online help for Rational Rose and the documentation for the language add-in you're using.
The Rational Rose ANSII C++ add-in enables you to reverse-engineer source code into a Rose model. ANSI C++ supports both reverse engineering into an empty model, where new model elements are created, and reverse engineering into an existing model, where model elements are changed to correspond to the code. It provides:
Rational Rose J enables you to reverse-engineer existing Java elements into a Rose model. These elements include:
Rational Rose J also supports integration with IBM's VisualAge for Java.
Rational Rose CORBA enables you to reverse engineer any CORBA-compliant IDL code into a Rose model. Each reverse-engineered .idl file becomes a component, and is placed in the component view of the model.
When you reverse engineer previously forward-engineered IDL code (that is, code that was generated from CORBA model elements), your original model elements remain unchanged, except that new information or changes you entered into the IDL code are carried back into the model. The exceptions to this rule are the special cases of Rational Rose constructs that are used for one-time forward engineering only.
Rational Rose XML DTD (eXtensible Markup Language Document Type Definition) reverse engineers an XML DTD (.dtd file) to create a Rose class diagram showing the structure, elements, and relationships in the DTD. You can add and remove XML DTD elements, and change relationships between the elements in the class diagram created by the reverse engineering process. After you use the Rose XML DTD syntax checker to validate the XML, you can generate a new DTD from the Rose class diagram.
Rational Rose XML DTD provides stereotyped classes you can use to model and generate an XML DTD.
Rational Rose Web Modeler parses Active Server Page (ASP), Java Server Page (JSP), and HTML files in your Web application creating a web application model using stereotype classes that represent client pages, server pages, and HTML forms. You can modify the Web application model and generate .asp, .jsp, .html, and .htm files from Web Modeler.
Rational Rose Data Modeler features allow the database designer and the software developer to communicate requirements using the same tool. As a database designer or developer, you can use Rose Data Modeler to model and design a database by reverse engineering an existing database schema or DDL script.
Using the Rational Rose Data Modeler Reverse Engineering Wizard, you can engineer a DDL script or database schema for an ANSI SQL 92 standard database or the following DBMSes:
The Reverse Engineering Wizard reads the database schema or DDL file and creates a data model diagram that includes the names of all quoted identifier entities. Depending on the DBMS, Rose Data Modeler Reverse Engineering Wizard models tables, relationships between tables, stored procedures, indexes, and triggers in the data model diagram.
In the data model diagram, you can add tables, define relationships, indexes, and domains, and apply third normal form to the elements, then transform the data model to an object model or forward engineer the data model to generate a DDL script or database schema.
Rational Unified Process