Difference between revisions of "Extensions.EventHandling.IsThresholdExceededEvent"
Jump to navigation
Jump to search
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{DISPLAYTITLE: '''IsThresholdExceededEvent'''}}[[Category:EventHandling]] | {{DISPLAYTITLE: '''IsThresholdExceededEvent'''}}[[Category:EventHandling]] | ||
== Classification == | == Classification == | ||
− | {{ClassificationActivity | IsThresholdExceededEvent | Checks whether an event comes '''ThresholdExceededEventSource''' | [[Term]] | [[Extensions.EventHandling|OTX EventHandling extension]] | [[Event source property related terms]] | - | - }} | + | {{ClassificationActivity | IsThresholdExceededEvent | Checks whether an event comes '''ThresholdExceededEventSource''' | [[Term]] | [[Extensions.EventHandling|OTX EventHandling extension]] | [[Extensions.EventHandling#Terms|Event source property related terms]] | - | - }} |
== OTL Syntax == | == OTL Syntax == | ||
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | <syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | ||
− | BooleanTerm | + | BooleanTerm EventHandling.IsThresholdExceededEvent(EventTerm event); |
</syntaxhighlight> | </syntaxhighlight> | ||
== Description == | == Description == | ||
− | The OTX '''IsThresholdExceededEvent''' term | + | The OTX '''IsThresholdExceededEvent''' term accepts an EventTerm yielding an Event object that has been raised by the OTX runtime, as a result of using a '''ThresholdExceededEventSource''' in a WaitForEvent action. The term shall return TRUE if and only if the Event originates from a '''ThresholdExceededEventSource'''. |
{{TermReturnValue| [[Core.DataTypes.SimpleDataType.Boolean|Boolean]] | Returns TRUE if the event comes from a '''ThresholdExceededEventSource'''.}} | {{TermReturnValue| [[Core.DataTypes.SimpleDataType.Boolean|Boolean]] | Returns TRUE if the event comes from a '''ThresholdExceededEventSource'''.}} | ||
Line 16: | Line 16: | ||
{| {{TableHeader}} | {| {{TableHeader}} | ||
{{TableRowPropertiesHeader}} | {{TableRowPropertiesHeader}} | ||
− | {{ | + | {{TableRowPropertie2| Event | [[Extensions.EventHandling.Event|Event]] | [[Term]] | - | [1] | The event, whose type is checked.}} |
|} | |} | ||
== OTL Examples == | == OTL Examples == | ||
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | <syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | ||
+ | /// Local Declarations | ||
+ | |||
Float LowerThreshold1 = 0; | Float LowerThreshold1 = 0; | ||
Float UpperThreshold1 = 1; | Float UpperThreshold1 = 1; | ||
Line 27: | Line 29: | ||
EventHandling.Event Event1; | EventHandling.Event Event1; | ||
Boolean Boolean1 = false; | Boolean Boolean1 = false; | ||
+ | |||
+ | /// Flow | ||
EventSource1 = EventHandling.ThresholdExceededEventSource(LowerThreshold1, UpperThreshold1, Variable1); | EventSource1 = EventHandling.ThresholdExceededEventSource(LowerThreshold1, UpperThreshold1, Variable1); | ||
Line 43: | Line 47: | ||
EventHandling.WaitForEvent({EventSource1}, Event1); | EventHandling.WaitForEvent({EventSource1}, Event1); | ||
− | + | terminateLanes; | |
} | } | ||
} | } |
Latest revision as of 09:35, 2 November 2018
Contents
Classification
Name | IsThresholdExceededEvent |
Short Description | Checks whether an event comes ThresholdExceededEventSource |
Class | Term |
Extension | OTX EventHandling extension |
Group | Event source property related terms |
Exceptions | - |
Checker Rules | - |
Standard Compliant | Yes |
OTL Syntax
BooleanTerm EventHandling.IsThresholdExceededEvent(EventTerm event);
Description
The OTX IsThresholdExceededEvent term accepts an EventTerm yielding an Event object that has been raised by the OTX runtime, as a result of using a ThresholdExceededEventSource in a WaitForEvent action. The term shall return TRUE if and only if the Event originates from a ThresholdExceededEventSource.
Return Value
The Term returns the value, see table below.
![]()
In OTX, Terms are categorized according to its return data type!
Data Type | Description |
Boolean | Returns TRUE if the event comes from a ThresholdExceededEventSource. |
Properties
Name | Data Type | Class | Default | Cardinality | Description |
Event | Event | Term | - | [1] | The event, whose type is checked. |
OTL Examples
/// Local Declarations
Float LowerThreshold1 = 0;
Float UpperThreshold1 = 1;
EventHandling.EventSource EventSource1;
Float Variable1 = 0;
EventHandling.Event Event1;
Boolean Boolean1 = false;
/// Flow
EventSource1 = EventHandling.ThresholdExceededEventSource(LowerThreshold1, UpperThreshold1, Variable1);
parallel
{
lane
{
while (true) : WhileLoop1
{
Variable1 = (Variable1 + 0.001);
}
}
lane
{
EventHandling.WaitForEvent({EventSource1}, Event1);
terminateLanes;
}
}
Boolean1 = EventHandling.IsThresholdExceededEvent(Event1);