previous next top contents index framed top this page unframed
Figure 3–1. MAINKERMIT Module Declaration
| MODULE kermit ( INTEGER PROCEDURE $executeKermitCommand (STRING cm; PRODUCES OPTIONAL STRING msg); STRING $prompt; ); |
The procedure $executeKermitCommand takes a STRING consisting of a single command line for the MAINKERMIT executive. $executeKermitCommand must be invoked once for each command line; you may not issue more than one line per call. The procedure returns a 0 if there were no errors, a 1 if there was an error, and a -1 if Kermit should cease execution (i.e., a QUIT command was given). If there is an error, an error message is returned in the string msg. The interface STRING $prompt is the prompt string with which MAINKERMIT would prompt the user; if it is to be changed, it may be set directly or by passing a SET PROMPT command to $executeKermitCommand.