Difference between revisions of "Extensions.DiagCom.IsDiagServiceEvent"

From emotive
Jump to navigation Jump to search
Line 3: Line 3:
 
{{ClassificationActivity | IsDiagServiceEvent | Checks whether an event was rased to a diagnostic service | [[Term]] | [[DiagCom|OTX DiagCom extension]] | [[Event related terms]] | - | - }}
 
{{ClassificationActivity | IsDiagServiceEvent | Checks whether an event was rased to a diagnostic service | [[Term]] | [[DiagCom|OTX DiagCom extension]] | [[Event related terms]] | - | - }}
  
== Pseudo-Code Syntax ==
+
== OTL Syntax ==
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
Boolean IsDiagServiceEvent(Event source);
+
BooleanTerm = DiagCom.IsDiagServiceEvent(EventTerm);
 
</syntaxhighlight>
 
</syntaxhighlight>
  
Line 19: Line 19:
 
|}
 
|}
  
== Examples ==
+
== OTL Examples ==
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
Boolean result = IsDiagServiceEvent(event);
+
DiagCom.ComChannel myComCannel;
 +
DiagCom.DiagService DiagService1;
 +
EventHandling.EventSource EventSource1;
 +
EventHandling.Event Event1;
 +
Boolean Boolean1 = false;
 +
 
 +
myComCannel = DiagCom.GetComChannel("LL_AirbaUDS", null, false);
 +
DiagService1 = DiagCom.CreateDiagServiceByName(myComCannel, "DiagnServi_ReadDataByIdentBasicSettiStatu");
 +
EventSource1 = DiagCom.DiagServiceEventSource(DiagService1);
 +
 
 +
parallel
 +
{
 +
  lane
 +
  {
 +
      DiagCom.ExecuteDiagService(DiagService1, {}, {}, false, false);
 +
  }
 +
  lane
 +
  {
 +
      EventHandling.WaitForEvent({EventSource1}, Event1);
 +
  }
 +
}
 +
 
 +
Boolean1 = DiagCom.IsDiagServiceEvent(Event1);
 
</syntaxhighlight>
 
</syntaxhighlight>
  

Revision as of 08:14, 6 February 2015

Classification

Name IsDiagServiceEvent
Short Description Checks whether an event was rased to a diagnostic service
Class Term
Extension OTX DiagCom extension
Group Event related terms
Exceptions -
Checker Rules -
Standard Compliant Yes

OTL Syntax

BooleanTerm = DiagCom.IsDiagServiceEvent(EventTerm);

Description

The IsDiagServiceEvent term checks whether the passed event so was rased to a diagnostic service on the DiagServiceEventSource was generated term or not, see Event Library.

Return Value

The Term returns the value, see table below.

Icons Note.png In OTX, Terms are categorized according to its return data type!
Data Type Description
Boolean True if and only if the Eventoriginates from a DiagServiceEventSourceterm, otherwise false.

Properties

Name Data Type Class Default Cardinality Description
Event Event Term - [1] Represents the Eventwhose type shall be tested.

OTL Examples

DiagCom.ComChannel myComCannel;
DiagCom.DiagService DiagService1;
EventHandling.EventSource EventSource1;
EventHandling.Event Event1;
Boolean Boolean1 = false;

myComCannel = DiagCom.GetComChannel("LL_AirbaUDS", null, false);
DiagService1 = DiagCom.CreateDiagServiceByName(myComCannel, "DiagnServi_ReadDataByIdentBasicSettiStatu");
EventSource1 = DiagCom.DiagServiceEventSource(DiagService1);

parallel
{
   lane
   {
      DiagCom.ExecuteDiagService(DiagService1, {}, {}, false, false);
   }
   lane
   {
      EventHandling.WaitForEvent({EventSource1}, Event1);
   }
}

Boolean1 = DiagCom.IsDiagServiceEvent(Event1);

See also

GetDiagServiceFromEvent
IsDiagServiceEvent