Hitachi

JP1 Version 12 JP1/Automatic Operation Service Template Reference


4.2.13 Branch by returncode plug-in

Function

This plug-in allows you to select which step to execute next based on the return code of the preceding step.

A branch by returncode plug-in connects to two branch destination steps: A succeeding step, and a step that is only executed when the judgment conditions is met. If the return code matches the judgment condition, JP1/AO executes the branch destination step and the succeeding step, in that order. If the return code does not match the judgment conditions, JP1/AO executes the succeeding step only.

By using this plug-in together with a test value plug-in, you can select the steps in a flow based on a character string.

Figure 4‒7: Branch by returncode plug-in

[Figure]

Cautionary notes

Version

01.10.01

Tag

Control Flow

Return codes

Return code

Description

0 or higher

The plug-in ended normally. The return code of the preceding step of the branch by returncode plug-in is set as the return code.

Property list

The following table describes the properties.

Property key

Property name

Description

Default value

I/O type

Required

condition

Condition

Specify the judgment condition for the return code of the preceding step. You can choose from the following conditions:

  • ReturnCode=value1

    The return code is equal to Value1.

  • ReturnCode!=value1

    The return code is not equal to Value1.

  • ReturnCode<value1

    The return code is less than Value1.

  • ReturnCode>value1

    The return code is greater than Value1.

  • ReturnCode<=value1

    The return code is less than or equal to Value1.

  • ReturnCode>=value1

    The return code is greater than or equal to Value1.

  • ReturnCode>value1 AND ReturnCode<value2

    The return code is greater than Value1 and less than Value2.

  • ReturnCode>=value1 AND ReturnCode<value2

    The return code is greater than or equal to Value1, and less than Value2.

  • ReturnCode>value1 AND ReturnCode<=value2

    The return code is greater than Value1, and less than or equal to Value2.

  • ReturnCode>=value1 AND ReturnCode<=value2

    The return code is greater than or equal to Value1, and less than or equal to Value2.

  • ReturnCode<value1 OR ReturnCode>value2

    The return code is less than Value1, or greater than Value2.

  • ReturnCode<=value1 OR ReturnCode>value2

    The return code is less than or equal to Value1, or greater than Value2.

  • ReturnCode<value1 OR ReturnCode>=value2

    The return code is less than Value1, or greater than or equal to Value2.

  • ReturnCode<=value1 OR ReturnCode>=value2

    The return code is less than or equal to Value1, or greater than or equal to Value2.

ReturnCode=value1

Input

R

value1

Value1

Specify a numerical value against which to judge the return code, within the range from 0 to 999.

The value is mapped to value1 in the condition property.

0

Input

R

value2

Value2

Specify a numerical value against which to judge the return code, within the range from 0 to 999.

The value is mapped to value2 in the condition property. This value takes effect when value2 is included in a condition property.

0

Input

O

Example of property specification

A branch by returncode plug-in determines whether the return code is within a specified range of values.

The following describes the range of valid judgment values, using the following values of the condition, value1, and value2 properties as examples.

A. The return code is 25 or greater and less than 75

condition (Condition): ReturnCode>=value1 AND ReturnCode<value2

value1 (Value1): 25

value2 (Value2): 75

B. The return code is less than 25, or 75 or higher

condition (Condition): ReturnCode<value1 ORReturnCode>=value2

value1 (Value1): 25

value2 (Value2): 75

The following figure shows the range of return codes that match each judgment condition.

Figure 4‒8: Range of return codes that match each judgment condition

[Figure]

Related topics