Try OpenEdge Now
skip to main content
Developing WebSpeed Applications
Controlling WebSpeed Transactions : Implementing transaction control : Overriding procedures and functions

Overriding procedures and functions

WebSpeed provides mechanisms for customizing procedures and functions in a way that never touches the default source code. Thus, you can effectively override any procedure or function as required.
You can override a procedure or function by having the WebSpeed Section Editor insert a local version of the procedure or function in your Web object. This local copy can contain a call to the default version, or it can completely replace the behavior of the default version. (For an example local override of a procedure, see Handling state-aware time-outs.)
You can also create an include file containing the definitions for your procedures and functions. (Examples of include files reside in install-path/src/web/method.) You can then reference these include files almost anywhere you write SpeedScript code, whether in embedded SpeedScript files or SpeedScript procedures. For information on coding include files references in SpeedScript procedures, see OpenEdge Development: ABL Reference.
Whenever you invoke a procedure or function, WebSpeed first looks for a local version of the procedure or function to execute. If that is not found, WebSpeed executes the default version. The default version is found in a super procedure that runs persistently on the WebSpeed agent.
A super procedure is an external procedure that runs persistently. Super procedures use the object oriented model for implementing and extending common behavior in applications. With super procedures, you can:
*Define standard behavior.
*Execute standard behavior.
*Override standard behavior with a local version.
*Supplement standard behavior either before or after execution.
*Overload or inherit multiple behavior classes.
For more information about creating and using super procedures, see OpenEdge Development: ABL Reference. Also see the AppBuilder online help.