Defining the local variables for an activity
Use the Local Variables section to create scalar variables.
Local variables are stored together as fields in the Java class that the Pega Platform generates to implement the activity. These require less memory and execute faster than regular parameters. They are often used to pass information from step to step.Local variables do not appear on the parameter page.
A local variable of type StringBuffer may be assembled in multiple steps, as a Property-Set on a StringBuffer appends the value to the StringBuffer.
Use the Local
keyword to reference a local variable in a Property-Set
method.
public StringBuffer aBuffer = new StringBuffer();
Field | Description |
Local Variables | |
Name | Enter the name you choose for the local variable, any legal Java identifier. See How to enter a Java identifier. Don't choose a name that starts with pz or any of the reserved names. |
Description | Enter a text description of this local variable, for information only. |
Data Type | Select the type of data that is expected as the value for the variable. Choose:
|
Local Action for Parameter Display | |
Local Action | Optional. Specify a flow action to use at runtime to produce a prompt form in which a user can enter values for the flow parameters specified in this tab. |
Previous topic Security tab on the Activity form Next topic Activity form - how to create activities for flows