status = disable ( method ) ;
list method
- Any variable that has a defined method.
str status
- $ACKNOWLEDGE
The method was disabled.
The STATUS variable is set to $ACKNOWLEDGE
- %UNDEFINED
Method 'name' is not a variable.
The STATUS variable is set to %UNDEFINED
- %BRANCH
Could not find 'method'.
The STATUS variable is set to %BRANCH
%UNDEFINED : Method 'name' is not a variable.
%BRANCH : Could not find 'method'.
%ARGUMENT : Invalid arguments. Usage: status = disable ( method ) ;
%IDENTIFIER : 'variable' argument is not a valid identifier, literal, or reference
An enabled method is available for execution by EVENT or QUERY messages. The disable method is used to prevent the method from being invoked by incoming EVENT or QUERY messages. All methods are disabled by default.
/*--Example 1 -------------------------------*/ connect() { /* Received connect message from sender. . . . */ return ; } /* Enable the connect method */ enable ( connect ); /* Enter IDLE state and wait for connect message */ idle(); /*--Example 2 -------------------------------*/ on_message CHECK_MESSAGE() ; . . . CHECK_MESSAGE() { /* If the incoming method is MYMETHOD, don't execute it */ if ( method() == "MYMETHOD" ) disable MYMETHOD : }