JsonArrayForEach (Json Array For Each)

This component passes each value of a JSON array to it’s output slot in sequence, with an intermediate delay between each item. An internal queue buffers the values. This may be used to process a list of items by linking the component to wiresheet logic that performs a task with each item.
Figure 92.   JsonArrayForEach properties
Image

You add this selector to a station by expanding Inbound > Selectors in the palette and dragging the JsonArrayForEach to a message router in the Nav tree.

In addition to the standard property (Enabled), these properties support the JsonArrayForEach.

Property Value Description
Last Result read-only Reports the results of the alarm acknowledgment to allow for logging or post-processing activity. Example output:

Unable to find messagge key:

Problem parsing messageType

Last Result Time read-only Reports when the handler ran last.
Last Input read-only Reports the last message routed to a component.
Status read-only Reflects the current status of the component.

Ok indicates the JSON processed successfully.

fault indicates the JSON did not process for any reason, such as invalid JSON or missing expected values in the JSON.

Out read-only The current array item, this will cycle once through each array item.
Numeric Out read-only Attempts to convert each item to a number as an out.
Boolean Out read-only Attempts to convert each item to a Boolean value as an out.
Default Between Items true or false (default) If true then the output slots are set to default values between each array item.
Queue read-only The queue component which buffers the array items.

Actions

These actions are available when you right-click on the JsonArrayForEach.

Figure 93.   JsonArrayForEach action buttons
Image
  • Route causes this component to process the String parameter and update the Out slot.
  • Run Last Input executes the last input again.
  • Clear Output sets the Out slot of this component to an empty string.