Download User's Guide SOTA 1.0 - 1 Introduction

Transcript
Fig.: Eclipse - New Java Class
Next it is necessary to include the logging component as a library in the project. In order to do this, the user has to copy
the file ASCLogger.jar from the SOTA directory into a folder lib in the root directory of the porject (..\workspace\Digit\).
On refreshing the project overview in Eclipse (F5) this file as well as the folder lib appear (see figure). Now the file has
to be added to the build path of the project by right-clicking ASCLogger.jar in the context menu and selecting Build
Path ->
Add to Build Path. The library is then included in the Referenced Libraries. With this the first phase - writing the
program and preparing it for instrumentation by SOTA- is completed.
Fig.: Proejct 'Digit' with
ASCLogger.jar ...
Fig.: ... and with
ASCLogger.jar added to build
path
2. SOTA: Preparatory Phase - Create Project
After starting SOTA via SOTA.exe the user has to create a project in SOTA for the test program. Selecting the menu
item
New Project opens a two-page wizard guiding the creation process.
On the first page the name of the project - Digit - as well as the root directory (project directory) of the proejct created
in point 1 have to be specified. The execution directory of the project is automatically linked to the same directory by
SOTA needing no user input since both directories are identical in this case. The first page of the wizard is now
completed and clicking the Next button calls the second page.
On the second page all sources of the project need to be imported. The project 'Digit' only consists of one file, so
marking the root directory is sufficient. The Finish button closes the wizard and then SOTA reads and parses the source
file.
Saving the project succesfully completes the creation process. When SOTA is started again, the project can be loaded via
the menu item
Open Project. Immediately after creating a project or loading an exisiting project respectively, the source code can be
viewed in the view Source and the control flow graph of each function is visible in the view CFG after selecting one in
the view Project. The static metrics that were computed while parsing the sources are now listed in the view Metrics.