concepts.pdsketch.regression_rule.LoopRegressionRuleBodyExpression#

class LoopRegressionRuleBodyExpression[source]#

Bases: object

A while-loop regression rule body. For example, in the definition of a regression rule, we can have a loop body expression like this:

LoopRegressionRuleBodyExpression(
    condition=condition,
    body=[
        OperatorApplicationExpression(...),
        AchieveExpression(...),
        ...
    ]
)

Methods

Attributes

condition

The condition of the loop regression rule body expression.

body

The body of the loop regression rule body expression.

__init__(condition, body)[source]#
Parameters:
__new__(**kwargs)#
body: Tuple[AchieveExpression | FindExpression | RuntimeAssignExpression | ListExpansionExpression | RegressionCommitFlag | OperatorApplicationExpression | RegressionRuleApplicationExpression | ConditionalRegressionRuleBodyExpression | LoopRegressionRuleBodyExpression, ...]#

The body of the loop regression rule body expression.

condition: ValueOutputExpression#

The condition of the loop regression rule body expression.