...
Code Block | ||||
---|---|---|---|---|
| ||||
FUNCTION xpfAddToAggrIfNotInAggr (aggrId aggr : AGGREGATE OF GENERIC; instanceIdelement : GENERIC) inserted : BOOLEAN; |
Use this function to ....add an element to aggregate if the aggregate does not have an element with the same value.
xpfAddToAggrIfNotInAggr(aggr, element) performs the same as the following statements:
IF NOT (element IN aggr) THEN aggr ++ element; END_IF;
Arguments
...
Type | Name | Comment |
AGGREGATE OF GENERIC | aggrId | comments |
GENERIC | instanceId |
...
Example
...
Code Block | ||
---|---|---|
| ||
<Missing Example>LOCAL OK : BOOLEAN; str : STRING; aggr: LIST OF STRING; END_LOCAL; ... str := 'QWERTY'; OK := xpfAddToAggrIfNotInAggr(aggr, str); IF OK THEN xpxPrintf('\n%s inserted', str); END_IF; ... |
See also
Filter by label (Content by label) | ||||||
---|---|---|---|---|---|---|
|
...