To execute the Map Algebra
Following we show the procedures to edit, execute and change a program in LEGAL.
Presentation of the development environment of programs in legal:

Program Development Window in LEGAL

Programs Toolbar in LEGAL
Description of the toolbar buttons:
-
- Creates a new program in LEGAL. It is necessary to define a file using the file dialog.
-
- Opens a program in LEGAL. It is necessary to select the file on the file dialog.
-
- Saves the program in LEGAL. Will always overwrite the selected file.
-
- Closes the program in LEGAL.
-
- Presents some programs in LEGAL which are distributed along with SPRING and the most recent program opened.
-
- Undoes editions of the program in LEGAL.
-
- Redoes editions of the program in LEGAL.
-
- Looks for texts into the program in LEGAL. A search window is presented, and through the window the seacrh can be performed.
-
- Executes the saved program in LEGAL. If there is a change, it would be necessary to save the program for the change to take effect.
-
- Executes a set of LEGAL programs. If there is a change, it would be necessary to save the program for the change to take effect.
-
- Prints the LEGAL program.
-
- Shows some tips about programming in LEGAL.
-
- Opens the Help of LEGAL programming.
-
- Shortcuts for variable declarations.
-
- Shortcuts for variable instantiations.
-
- Shortcuts for LEGAL language operations.
-
- Shortcuts for LEGAL language mathematical operations.
Creating and Executing a Program in LEGAL:
-
In the Main Menu click on <LEGAL> <Analysis..>. The "LEGAL" window will be presented.;
-
In the "LEGAL" window click on
, select the path and file where the program will be stored. It is recommended to create a sub-directory
(folder) under the directory where the database is located, so when you make a backup copy, your program will also be saved;
-
The text field will be enabled to the LEGAL program development.Type the program;
-
Click
to save the program;
-
Click
to execute the program;
OBS1: If syntax or invalid command errors occur, the message "Syntax Error of the Program. Check for errors on the console!" will be
presented and the errors will be presented on the component "Syntax Errors of the Program".
For each error occurrence, the errors and the correspondent line numbers will be indicated. Make the corrections, save the changes and try to execute the program again.
By the end of the program's execution, the output infolayers and cadastrals objects can be checked on the "Control
Panel".
Changing a LEGAL Program:
-
In the Main Menu click on <LEGAL> <Analysis..>. The "LEGAL" window will be presented.;
-
In the "LEGAL" window, click on
, select the file that corresponds to the LEGAL program;
-
Make the changes you want;
-
Click
to save the program;
-
Click
to execute the program;
Executing many LEGAL programs:
-
Click
to open the selection window and execution order;
-
Use the buttons to choose the execution order
and
;
-
Mark the programs you would like to execute;
-
Click on the button Execute;
Programming in Legal - Map Algebra
See also:
Analysis Options in SPRING !
Numeric Modeling
Image Processing