Class: QgsEsriArcadeIfStatement

Represents an if statement.

Added in version 4.4.

List of all members, including inherited members

Class Hierarchy

Inheritance diagram of qgis.core.QgsEsriArcadeIfStatement

Base classes

QgsEsriArcadeStatement

Base class for statement nodes in an Esri Arcade script.

QgsEsriArcadeNode

Represents an abstract node for an Esri Arcade script.

Constructor

__init__

Abstract Methods

clone

Methods

condition

Returns the condition expression.

falseBlock

Returns the statement block executed when the condition evaluates to False, or None if none.

trueBlock

Returns the statement block executed when the condition evaluates to True.

class qgis.core.QgsEsriArcadeIfStatement[source]

Bases: QgsEsriArcadeStatement

__init__(condition: QgsEsriArcadeExpression | None, trueBlock: QgsEsriArcadeBlockStatement | None, falseBlock: QgsEsriArcadeBlockStatement | None = None)

Constructor for QgsEsriArcadeIfStatement.

Ownership of condition, trueBlock, and falseBlock is transferred to this statement.

Parameters:
abstract clone(self) → QgsEsriArcadeNode | None[source]
Return type:

QgsEsriArcadeNode|None

condition(self) → QgsEsriArcadeExpression | None[source]

Returns the condition expression.

Return type:

QgsEsriArcadeExpression|None

falseBlock(self) → QgsEsriArcadeBlockStatement | None[source]

Returns the statement block executed when the condition evaluates to False, or None if none.

Return type:

QgsEsriArcadeBlockStatement|None

trueBlock(self) → QgsEsriArcadeBlockStatement | None[source]

Returns the statement block executed when the condition evaluates to True.

Return type:

QgsEsriArcadeBlockStatement|None