(14 out of 18)
Activator Code
The Activator Code interface allows the developer to add C/C++ code to Object Bindings and Activators. See Generated Code in the Reference Manual for more information. There are 6 places that are significant for adding code:
- 1.
/* #includes, #defines, globals, other code */
- This section allows the user to add code that is significant to the entire module. Any valid code can be added here.
- 2.
/* Function Initialization Code */
- This code is inserted at the top of the generated function and is associated with the Activator listed in the title bar of The Activator Code interface. Local variables can be declared here, as well as initial code.
- 3.
/* Before Object Binding Execution Code */
- This is code which gets executed immediately before the generated code for the selected Object Binding is executed.
- 4.
/* Object Binding Execution Code */
- This is a scrolled list containing a list of all Object Bindings associated with the Activator displayed in the title bar. When a binding is selected, its before and after code gets loaded into the respective Activator Code sections, allowing the function developer to easily view the flow of the code. Pressing the button on the right of the Binding List reorders the way the bindings are executed. Pressing the button on the left brings up the Object Bind Editor for the selected Object Binding.
- 5.
/* After Object Binding Execution Code */
- This is code which is executed immediately after the generated code for a selected Object Binding is executed.
- 6.
/* Function Final Code */
- This code is executed after all Object Binding code has been executed. It is often used for cleaning up allocated memory. See Figure 1-15 for locations of the above steps previously discussed in the begin.html<A>begin screen.
Figure 1-15 Activator Code
(14 out of 18)