Try OpenEdge Now
skip to main content
Open Client Introduction and Programming
Overview : Accessing AppServer functionality : The object model : ABL procedures
 
ABL procedures
Before describing the three types of proxy objects, it helps to understand basic concepts governing the operation of ABL procedures. First, any file that is executable by ABL is an external procedure. An external procedure can contain one or more internal procedures or user-defined functions that execute within and share the context of the external procedure. You can execute an external procedure as a:
*Non-persistent procedure — The procedure executes and returns to the caller, removing all trace of its context from memory after returning. Any internal procedures and functions that it defines can be executed only by the procedure itself. A non-persistent procedure executes and returns as a unit without exposing any of its context to the caller.
*Persistent procedure — The main block of the procedure executes and returns to the caller, but unlike non-persistent procedures, a persistent procedure leaves its context active after completing execution. Internal procedures and user-defined functions remain available for future execution.
*Single-run procedure — The procedure is instantiated and the main block is run only when an internal procedure or user-defined function that it defines is invoked. The single-run procedure is then deleted when the internal procedure or user-defined function completes. A procedure with parameters in its main block cannot be used with the single-run option.
*Singleton procedure — The procedure is instantiated and the main block is run only when an internal procedure or user-defined function that it defines is invoked, and only then if the singleton procedure has not already been instantiated for a previous invocation. Unlike the single-run option, a singleton remains instantiated after its internal procedure or user-defined function completes. The procedure remains instantiated and is used the next time one of its internal procedures or user-defined functions is run. A procedure with parameters in its main block cannot be used with the single-run option.
For more information on single-run and singleton procedures, see OpenEdge Application Server: Developing AppServer Applications.
Note: For the purposes of this book, OpenEdge Development: Java Open Clients, and OpenEdge Development: .NET Open Clients, the term "non-persistent procedures�? does NOT include single-run or singleton procedures.