Reversing

 

Introduction

The reverse process allows existing library classes to be used during the modeling phase. This process allows the generalization of these classes, as well as their implementation or their use in modeling.

 

To reverse a class, you must have an .exe or .dll file of a C# project that includes this class.  If you also have the .cs source code, a complete reverse of the code and C# documentation comments can be carried out.  If this is not the case, only a structural reverse will be carried out.

 

 

Warning

A class created through a reverse will receive an identifier in the same way as an object created in an explorer or in a graphic editor.

 

If two people reverse the same class in two different projects, Objecteering will consider them as two different objects.

 

To avoid losing links to the reversed classes during the reverse, run the reverse operation in the project from which all the classes used are imported.

 

 

Running the "Reverse" command

The reverse operation can be run from any element (as shown in Figure 26).

 

Figure 26. Running the reverse operation

 

Steps:

·         Select the "Bank" package in the explorer.

·         Click on the  icon in the toolbar.

 

 

Selecting the classes to be reversed

The reverse command opens the dialog boxes used to select the .exe or .dll file including the class to reverse, as represented below in Figure 27.

 

Figure 27. Selecting the classes to be reversed

 

Steps:

1.      Select the file to reverse.

2.      Select the reverse option (full, mixed or simple).

3.      Click on the "Next" button to open the next window.

4.      Select the components that are to be reversed.

5.      Click on the "Next " button to launch the reverse.

 

 

Result

A package named "Calculator" appears (see Figure 28). It contains the "Operation" class.

 

Figure 28. Result of the reverse as seen in the explorer

 

For more information on reverse operations, please see "Overview of the C# reverse".