Difference between revisions of "Core.Actions.Throw"

From emotive
Jump to navigation Jump to search
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
 
{{DISPLAYTITLE:OTX '''Throw'''}}[[Category:Core]]
 
{{DISPLAYTITLE:OTX '''Throw'''}}[[Category:Core]]
 
== Classification ==
 
== Classification ==
{{ClassificationActivity | Throw | To explicitly raise of an exception | [[End Node]] | [[OtxReference#Core|OTX Core library]] | [[End node related actions]] | - | [[Core.Validation.CoreChk017|Core_Chk017]]<br/>[[Core.Validation.CoreChk018|Core_Chk018]] }}
+
{{ClassificationActivity | Throw | To explicitly raise of an exception | [[End Node]] | [[Core|OTX Core library]] | [[End node related actions]] | - | [[Core.Validation.CoreChk017|Core_Chk017]]<br/>[[Core.Validation.CoreChk018|Core_Chk018]] }}
  
 
== OTL Syntax ==
 
== OTL Syntax ==
Line 9: Line 9:
  
 
== Description ==
 
== Description ==
With the OTX throw activity [[Exception]]s can be triggered explicitly, by the author. Typically, exceptions are, implicitly thrown by the runtime environment. For example, faulty calculations, the loss of communication or the occurrence of a negative response. Using the throw activity the user can cause your own exceptions however in error conditions. The [[Core.Actions.Handler|Handler]] activity can to respond to exceptions.
+
With the OTX throw activity [[Core.Actions.Throw.Exception|Exception]]s can be triggered explicitly, by the author. Typically, exceptions are, implicitly thrown by the runtime environment. For example, faulty calculations, the loss of communication or the occurrence of a negative response. Using the throw activity the user can cause your own exceptions however in error conditions. The [[Core.Actions.Handler|Handler]] activity can to respond to exceptions.
  
 
{{Important|Please note the special behavior within an [[Core.Actions.Parallel|Parallel]] activity.}}
 
{{Important|Please note the special behavior within an [[Core.Actions.Parallel|Parallel]] activity.}}

Latest revision as of 09:01, 16 February 2016

Classification

Name Throw
Short Description To explicitly raise of an exception
Class End Node
Extension OTX Core library
Group End node related actions
Exceptions -
Checker Rules Core_Chk017
Core_Chk018
Standard Compliant Yes

OTL Syntax

throw ExceptionTerm;

Description

With the OTX throw activity Exceptions can be triggered explicitly, by the author. Typically, exceptions are, implicitly thrown by the runtime environment. For example, faulty calculations, the loss of communication or the occurrence of a negative response. Using the throw activity the user can cause your own exceptions however in error conditions. The Handler activity can to respond to exceptions.

Exclamation.png Important: Please note the special behavior within an Parallel activity.

OTL Examples

UserException userException;
String stringVar1;
Boolean Condition1 = true;

if (Condition1)
{
   throw userException;
}
else
{
}

stringVar1 = "I will never happen because of the Throw";

See also

Return
Continue
Break
TerminateLanes