Class: QgsVbScriptWhileStatement

Represents a while loop statement.

Added in version 4.4.

List of all members, including inherited members

Class Hierarchy

Inheritance diagram of qgis.core.QgsVbScriptWhileStatement

Base classes

QgsVbScriptStatement

Base class for statement nodes in a VBScript script.

QgsVbScriptNode

Represents an abstract node for a VBScript script.

Constructor

__init__

Enums

LoopType

Type of while or do loop.

Abstract Methods

clone

Methods

body

Returns the loop body block statement.

condition

Returns the loop condition expression.

loopType

Returns the loop variant type.

class qgis.core.QgsVbScriptWhileStatement[source]

Bases: QgsVbScriptStatement

__init__(loopType: QgsVbScriptWhileStatement.LoopType, condition: QgsVbScriptExpression | None, body: QgsVbScriptBlockStatement | None)

Constructor for QgsVbScriptWhileStatement.

Ownership of condition and body is transferred to this statement.

Parameters:
class LoopType(*values)

Bases: Enum

Type of while or do loop.

  • WhileWend: While … Wend loop

  • DoWhile: Do While … Loop

  • DoUntil: Do Until … Loop

  • DoLoopWhile: Do … Loop While

  • DoLoopUntil: Do … Loop Until

DoLoopUntil = 4
DoLoopWhile = 3
DoUntil = 2
DoWhile = 1
WhileWend = 0
body(self) → QgsVbScriptBlockStatement | None[source]

Returns the loop body block statement.

Return type:

QgsVbScriptBlockStatement|None

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

QgsVbScriptNode|None

condition(self) → QgsVbScriptExpression | None[source]

Returns the loop condition expression.

Return type:

QgsVbScriptExpression|None

loopType(self) → QgsVbScriptWhileStatement.LoopType[source]

Returns the loop variant type.

Return type:

QgsVbScriptWhileStatement.LoopType