Start » Filter Reference » Data Flow » Loop Utils » TestObjectChanged
Module: | FoundationLite |
---|
Checks if the input object is different than in the previous iteration.
Name | Type | Description | |
---|---|---|---|
inObject | <T> | ||
inInitialResult | Bool | Result of the filter at first iteration | |
inReset | Bool | Reset accumulator state | |
outObjectChanged | Bool | Is object changed | |
outPreviousObject | <T> | Object from previous iteration (in first iteration equals inObject) |
The type of this filter is defined using the type variable T which represents any valid type. Read more.
Description
This filter checks if an object has changed between consecutive iterations. It is especially useful in working with I/O and allows to execute a part of an application only when some I/O data has changed. This filter can be also used as an input of macrofilter variant.
Input inInitialResult allows for setting the initial output of the filter. This is useful to force some computations at the start of application.
In first iteration output outPreviousObject is equal to value on inObject
Remarks
When working with HMI, a more recommended way of detecting changes is to use appropriate properties of HMI Controls such as TrackBar.outValueChanged.
This filter can be replaced with the following formula:
Complexity Level
This filter is available on Basic Complexity Level.
See Also
- CopyObject – Creates a copy of the input data.