Process method: PTRTI class
Syntax
Process(&triggerrec, &searchdefn, &keys, &keyvalueset)
Description
Use the Process method to perform the following activities:
-
Preprocessing: Performs the preprocessing task that was performed by an Application Engine program in a search definition.
-
Defer processing of current entries.
-
Discard processing of current entries.
Parameters
| Parameter | Description |
|---|---|
|
&triggerrec |
Specifies the name of the trigger record as a String. For Activity Guide type search definitions, the value of the &triggerrec parameter is always PTAI_ITEM. |
|
&searchdefn |
Specifies the name of the search definition as a String. |
|
&keys |
Specifies the key names as in a staging row as an array of String. |
|
&keyvalueset |
Specifies the key values of the keys as in a staging row as an array of array of String. |
Returns
An array of number with exactly one of the following values.
| Value | Description |
|---|---|
|
0 |
Defers the entry. |
|
1 |
Processes the entry. |
|
-1 |
Discards the entry. |
If the method returns an array of numbers consisting of only one array element, the same value is applied to all the entries.
For example, if the keyvalueset has five rows and the return value is 1 (processes the entry), the return value 1 is applied to all the five rows, that is, processing the five rows.
Example
import PTRTIPKG:PTRTI;
class RTI extends PTRTIPKG:PTRTI
method Process(&triggerrec As string, &searchdefn As string, &keys As array of string, &keyvalueset As array of array of string) Returns array of number;
end-class;
method Process
/+ &triggerrec as String, +/
/+ &searchdefn as String, +/
/+ &keys as Array of String, +/
/+ &keyvalueset as Array2 of String +/
/+ Returns Array of Number +/
/+ Extends/implements PTRTIPKG:PTRTI.Process +/
Local array of number &aresult;
&aresult = CreateArrayRept(0, 1);
&aresult.Push(1);
/* Perform some processing */
Return &aresult;
end-method;
Related Topics