Product Site

15.4.2. Multithreaded Additions to TRACE

To ease debugging of multithreaded programs the execution context will be displayed with a "multithreaded trace prefix string" in square brackets (see also the class method makeStringImpl and the class attribute "option" of the "TraceObject class) in the following form, if the class attribute option is set to "F" (full):

"[R1 T2 I3 Gu A4 L5 *W]", where

If currently tracing methods then in addition the following information gets displayed:

Notes:

Starting with ooRexx 5.1, each traced line will be represented with an instance of its new class TraceObject. Its class attribute "option" is set to "N" (normal) by default. If one needs the additional, multithreaded related trace information prefixed in square brackets then changing the class attribute "option" to "S" (standard) or to "F" (full, for complex multithreaded programs) will prepend it to each traced line. Each such TraceObject instance will be sent as the argument to the LINEOUT message to the .traceOutput monitor object. As .traceOutput monitor needs a string value for display it will send the request("STRING") message to it, causing the TraceObject's makeString method to run and to return the string value that represents it.

If one wishes to intercept the generated TraceObject instances then one could take advantage of TraceObject's class attribute collector.