CxStatementIf

Description

sealed class Tinman.Core.Cx.Statements.CxStatementIf

Derived from

CxStatement abstract

A statement that selectively executes a body statement, based on the result of a condition expression:

if (a)
  b = 1;

if (a)
  b = 1;
else
  b = 2;

Public / Constructors

CxStatementIf


public constructor CxStatementIf → (3)

condition in : CxExpression

[not-null]
See Condition.

statementTrue in : CxStatement

[not-null]
See StatementTrue.

statementFalse opt : CxStatement = null

See StatementFalse.

Creates a new instance of CxStatementIf.

Public / Attributes

Condition


public attribute Condition → (get)

value : CxExpression

[not-null]
The condition expression.

Returns the condition expression.

StatementFalse


public attribute StatementFalse → (get)

value : CxStatement

The statement to execute if the condition is false or null if no statement shall be executed in this case.

Returns the statement to execute when the condition is false.

StatementTrue


public attribute StatementTrue → (get)

value : CxStatement

[not-null]
The statement to execute if the condition is true.

Returns the statement to execute when the condition is true.