pyGHDL.dom.Sequential

Classes


Classes

class pyGHDL.dom.Sequential.IfBranch(branchNode, condition, statements=None)[source]

Inheritance

Inheritance diagram of IfBranch

Parameters:
__init__(branchNode, condition, statements=None)[source]

Initializes an if branch.

Parameters:
  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition guarding this statement.

  • statements (Iterable[SequentialStatement]) – List of all sequential statements in this construct.

  • parent – The parent model entity of this entity.

  • branchNode (Iir)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Statements: List[SequentialStatement]

Read-only property to access the list of sequential statements (_statements).

Returns:

A list of sequential statements.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_parent

Reference to a parent entity in the logical model hierarchy.

_statements

List of all sequential statements in this construct.

class pyGHDL.dom.Sequential.ElsifBranch(branchNode, condition, statements=None)[source]

Inheritance

Inheritance diagram of ElsifBranch

Parameters:
__init__(branchNode, condition, statements=None)[source]

Initializes an elsif branch of an if statement.

Parameters:
  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition guarding this statement.

  • statements (Iterable[SequentialStatement]) – List of all sequential statements in this construct.

  • parent – The parent model entity of this entity.

  • branchNode (Iir)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Statements: List[SequentialStatement]

Read-only property to access the list of sequential statements (_statements).

Returns:

A list of sequential statements.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_parent

Reference to a parent entity in the logical model hierarchy.

_statements

List of all sequential statements in this construct.

class pyGHDL.dom.Sequential.ElseBranch(branchNode, statements=None)[source]

Inheritance

Inheritance diagram of ElseBranch

Parameters:
__init__(branchNode, statements=None)[source]

Initializes an else branch.

Parameters:
  • statements (Iterable[SequentialStatement]) – List of all sequential statements in this construct.

  • parent – The parent model entity of this entity.

  • branchNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Statements: List[SequentialStatement]

Read-only property to access the list of sequential statements (_statements).

Returns:

A list of sequential statements.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_statements: List[SequentialStatement]

List of all sequential statements in this construct.

class pyGHDL.dom.Sequential.IfStatement(ifNode, ifBranch, elsifBranches=None, elseBranch=None, label=None)[source]

Inheritance

Inheritance diagram of IfStatement

Parameters:
__init__(ifNode, ifBranch, elsifBranches=None, elseBranch=None, label=None)[source]

Initializes an if statement.

Parameters:
  • ifBranch (IfBranch) – The mandatory if branch.

  • elsifBranches (Iterable[ElsifBranch]) – List of all elsif branches, in the order they were written.

  • elseBranch (ElseBranch) – The optional else branch, or None if none was given.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • ifNode (Iir)

Return type:

None

property ElsIfBranches: List[ElsifBranch]

Read-only property to access the elsif-branch of the if-statement (_elsifBranch).

Returns:

The elsif-branch.

property ElseBranch: <pyTooling.Decorators.readonly object at 0x7c5266a66f50> | None

Read-only property to access the else-branch of the if-statement (_elseBranch).

Returns:

The else-branch.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property IfBranch: <pyTooling.Decorators.readonly object at 0x7c5266a66e50>

Read-only property to access the if-branch of the if-statement (_ifBranch).

Returns:

The if-branch.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_elseBranch: <pyTooling.Decorators.readonly object at 0x7c5266a66f50> | None

The optional else branch, or None if none was given.

_elsifBranches: List[ElsifBranch]

List of all elsif branches, in the order they were written.

_ifBranch: <pyTooling.Decorators.readonly object at 0x7c5266a66e50>

The mandatory if branch.

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.IndexedChoice(node, expression)[source]

Inheritance

Inheritance diagram of IndexedChoice

Parameters:
__init__(node, expression)[source]

Initializes a case choice given by a single value.

Parameters:
  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The expression this choice selects on.

  • parent – The parent model entity of this entity.

  • node (Iir)

Return type:

None

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

__str__()[source]

Formats the indexed case choice.

Format: 0

Return type:

str

Returns:

Formatted indexed case choice.

_expression

The expression this choice selects on.

_parent

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.RangedChoice(node, rng)[source]

Inheritance

Inheritance diagram of RangedChoice

Parameters:
__init__(node, rng)[source]

Initializes a case choice given by a range.

Parameters:
  • rng (Range) – The range this choice selects on.

  • parent – The parent model entity of this entity.

  • node (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Range: Range

Read-only property to access the range (_range).

Returns:

The range.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

__str__()[source]

Formats the ranged case choice.

Format: 0 to 3

Return type:

str

Returns:

Formatted ranged case choice.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_range: Range

The range this choice selects on.

class pyGHDL.dom.Sequential.Case(node, choices, statements=None)[source]

Inheritance

Inheritance diagram of Case

Parameters:
__init__(node, choices, statements=None)[source]

Initializes a case.

Parameters:
Return type:

None

property Choices: List[BaseChoice]

Read-only property to access the choices (_choices).

Returns:

List of choices.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Statements: List[SequentialStatement]

Read-only property to access the list of sequential statements (_statements).

Returns:

A list of sequential statements.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

__str__()[source]

Formats the case alternative.

Format: when 0 | 1 =>

Return type:

str

Returns:

Formatted case alternative.

_choices: List[BaseChoice]

List of all choices selecting this alternative.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_statements: List[SequentialStatement]

List of all sequential statements in this construct.

class pyGHDL.dom.Sequential.OthersCase(caseNode, statements=None)[source]

Inheritance

Inheritance diagram of OthersCase

Parameters:
__init__(caseNode, statements=None)[source]

Initializes a sequential case.

Parameters:
  • statements (Iterable[SequentialStatement]) – List of all sequential statements in this construct.

  • choices – List of all choices selecting this alternative.

  • parent – The parent model entity of this entity.

  • caseNode (Iir)

Return type:

None

property Choices: List[BaseChoice]

Read-only property to access the choices (_choices).

Returns:

List of choices.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Statements: List[SequentialStatement]

Read-only property to access the list of sequential statements (_statements).

Returns:

A list of sequential statements.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

__str__()[source]

Formats the others case alternative.

Format: when others =>

Return type:

str

Returns:

Formatted others case alternative.

_choices: List[BaseChoice]

List of all choices selecting this alternative.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_statements: List[SequentialStatement]

List of all sequential statements in this construct.

class pyGHDL.dom.Sequential.CaseStatement(caseNode, label, expression, cases)[source]

Inheritance

Inheritance diagram of CaseStatement

Parameters:
__init__(caseNode, label, expression, cases)[source]

Initializes a case statement.

Parameters:
  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The expression being tested.

  • cases (Iterable[SequentialCase]) – List of all alternatives, in the order they were written.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • caseNode (Iir)

Return type:

None

property Cases: List[SequentialCase]

Read-only property to access the cases (_cases).

Returns:

List of cases.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property SelectExpression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the select expression (_expression).

Returns:

The select expression.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_cases

List of all alternatives, in the order they were written.

_expression

The expression being tested.

_label

The label of a model entity.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.ForLoopStatement(loopNode, loopIndex, rng, statements=None, label=None)[source]

Inheritance

Inheritance diagram of ForLoopStatement

Parameters:
__init__(loopNode, loopIndex, rng, statements=None, label=None)[source]

Initializes a for-loop statement.

Parameters:
  • loopIndex (str) – The name of the loop’s index.

  • rng (Range) – The range the loop iterates over.

  • statements (Iterable[SequentialStatement]) – List of all sequential statements in this construct.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • loopNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property LoopIndex: str

Read-only property to access the loop index (_loopIndex).

Returns:

The loop index.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Range: <pyTooling.Decorators.readonly object at 0x7c5266ab4150>

Read-only property to access the range (_range).

Returns:

The range.

property Statements: List[SequentialStatement]

Read-only property to access the list of sequential statements (_statements).

Returns:

A list of sequential statements.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_label: str | None

The label of a model entity.

_loopIndex: str

The name of the loop’s index.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_range: <pyTooling.Decorators.readonly object at 0x7c5266ab4150>

The range the loop iterates over.

_statements: List[SequentialStatement]

List of all sequential statements in this construct.

class pyGHDL.dom.Sequential.WhileLoopStatement(loopNode, condition, statements=None, label=None)[source]

Inheritance

Inheritance diagram of WhileLoopStatement

Parameters:
__init__(loopNode, condition, statements=None, label=None)[source]

Initializes a while-loop statement.

Parameters:
  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition guarding this statement.

  • statements (Iterable[SequentialStatement]) – List of all sequential statements in this construct.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • loopNode (Iir)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Statements: List[SequentialStatement]

Read-only property to access the list of sequential statements (_statements).

Returns:

A list of sequential statements.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_label

The label of a model entity.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

_statements

List of all sequential statements in this construct.

class pyGHDL.dom.Sequential.SequentialSimpleSignalAssignment(assignmentNode, target, waveform, label=None)[source]

Inheritance

Inheritance diagram of SequentialSimpleSignalAssignment

Parameters:
__init__(assignmentNode, target, waveform, label=None)[source]

Initializes a simple sequential signal assignment.

Parameters:
  • target (SignalSymbol) – Reference to the assignment’s destination.

  • waveform (Iterable[WaveformElement]) – List of all waveform elements, in the order they were written.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Target: SignalSymbol

Read-only property to access the target (_target).

Returns:

The target.

property Waveform: List[WaveformElement]

Read-only property to access the waveform (_waveform).

Returns:

List of waveform.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_target: Symbol

Reference to the assignment’s destination.

_waveform: List[WaveformElement]

List of all waveform elements, in the order they were written.

class pyGHDL.dom.Sequential.ConditionalExpression(node, expression, condition=None)[source]

Inheritance

Inheritance diagram of ConditionalExpression

Parameters:
__init__(node, expression, condition=None)[source]

Initializes a conditional expression.

Parameters:
  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The value assigned when the condition holds.

  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition selecting this alternative.

  • parent – The parent model entity of this entity.

  • node (Iir)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_expression

The expression held by this construct.

_parent

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.SelectedExpression(node, choices, expression)[source]

Inheritance

Inheritance diagram of SelectedExpression

Parameters:
__init__(node, choices, expression)[source]

Initializes a selected expression.

Parameters:
  • choices (Iterable) – List of all choices selecting this alternative.

  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The value assigned for the matching choices.

  • parent – The parent model entity of this entity.

  • node (Iir)

Return type:

None

property Choices: List[BaseChoice]

Read-only property to access the choices (_choices).

Returns:

List of choices.

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_choices: List[BaseChoice]

List of all choices selecting this alternative.

_expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

The expression held by this construct.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.OthersSelectedExpression(node, expression)[source]

Inheritance

Inheritance diagram of OthersSelectedExpression

Parameters:
__init__(node, expression)[source]

Initializes an others selected expression.

Parameters:
  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The value assigned for every unnamed choice.

  • parent – The parent model entity of this entity.

  • node (Iir)

Return type:

None

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

The expression held by this construct.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.SequentialVariableAssignment(assignmentNode, target, expression, label=None)[source]

Inheritance

Inheritance diagram of SequentialVariableAssignment

Parameters:
__init__(assignmentNode, target, expression, label=None)[source]

Initializes a simple sequential variable assignment.

Parameters:
  • target (VariableSymbol) – Reference to the assignment’s destination.

  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The assigned expression.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Target: VariableSymbol

Read-only property to access the target (_target).

Returns:

The target.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

The assigned expression.

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_target: Symbol

Reference to the assignment’s destination.

class pyGHDL.dom.Sequential.SequentialConditionalVariableAssignment(assignmentNode, target, conditionalExpressions, label=None)[source]

Inheritance

Inheritance diagram of SequentialConditionalVariableAssignment

Parameters:
__init__(assignmentNode, target, conditionalExpressions, label=None)[source]

Initializes a conditional sequential variable assignment.

Parameters:
  • target (VariableSymbol) – Reference to the assignment’s destination.

  • conditionalExpressions (Iterable[ConditionalExpression]) – List of all alternatives, in the order they were written.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

property ConditionalExpressions: List[ConditionalExpression]

Read-only property to access the conditional expressions (_conditionalExpressions).

Returns:

List of conditional expressions.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Target: Symbol

Read-only property to access the target (_target).

Returns:

The target.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_conditionalExpressions: List[ConditionalExpression]

List of all alternatives, in the order they were written.

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_target: Symbol

Reference to the assignment’s destination.

class pyGHDL.dom.Sequential.SequentialConditionalSignalAssignment(assignmentNode, target, conditionalWaveforms, label=None)[source]

Inheritance

Inheritance diagram of SequentialConditionalSignalAssignment

Parameters:
__init__(assignmentNode, target, conditionalWaveforms, label=None)[source]

Initializes a conditional sequential signal assignment.

Parameters:
  • target (SignalSymbol) – Reference to the assignment’s destination.

  • conditionalWaveforms (Iterable) – All alternatives, in order.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

property ConditionalWaveforms: List[ConditionalWaveform]

Read-only property to access the conditional waveforms (_conditionalWaveforms).

Returns:

List of conditional waveforms.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Target: SignalSymbol

Read-only property to access the target (_target).

Returns:

The target.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_conditionalWaveforms: List[ConditionalWaveform]

All alternatives, in order.

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_target: Symbol

Reference to the assignment’s destination.

class pyGHDL.dom.Sequential.SequentialSelectedVariableAssignment(assignmentNode, target, expression, selectedExpressions, label=None)[source]

Inheritance

Inheritance diagram of SequentialSelectedVariableAssignment

Parameters:
__init__(assignmentNode, target, expression, selectedExpressions, label=None)[source]

Initializes a selected sequential variable assignment.

Parameters:
  • target (VariableSymbol) – Reference to the assignment’s destination.

  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The selector expression.

  • selectedExpressions (Iterable) – All alternatives, in order.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property SelectedExpressions: List[SelectedExpression | OthersSelectedExpression]

Read-only property to access the selected expressions (_selectedExpressions).

Returns:

List of selected expressions.

property Target: Symbol

Read-only property to access the target (_target).

Returns:

The target.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

The expression held by this construct.

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_selectedExpressions: List[SelectedExpression | OthersSelectedExpression]

All alternatives, in order.

_target: Symbol

Reference to the assignment’s destination.

class pyGHDL.dom.Sequential.SequentialSelectedSignalAssignment(assignmentNode, target, expression, selectedWaveforms, label=None)[source]

Inheritance

Inheritance diagram of SequentialSelectedSignalAssignment

Parameters:
__init__(assignmentNode, target, expression, selectedWaveforms, label=None)[source]

Initializes a selected sequential signal assignment.

Parameters:
  • target (SignalSymbol) – Reference to the assignment’s destination.

  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The selector expression.

  • selectedWaveforms (Iterable) – All alternatives, in order.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property SelectedWaveforms: List[SelectedWaveform | OthersSelectedWaveform]

Read-only property to access the selected waveforms (_selectedWaveforms).

Returns:

List of selected waveforms.

property Target: SignalSymbol

Read-only property to access the target (_target).

Returns:

The target.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

The expression held by this construct.

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_selectedWaveforms: List[SelectedWaveform | OthersSelectedWaveform]

All alternatives, in order.

_target: Symbol

Reference to the assignment’s destination.

class pyGHDL.dom.Sequential.SignalForceAssignment(assignmentNode, target, expression, label=None)[source]

Inheritance

Inheritance diagram of SignalForceAssignment

Parameters:
__init__(assignmentNode, target, expression, label=None)[source]

Initializes a signal force assignment.

Parameters:
  • target (SignalSymbol) – Reference to the assignment’s destination.

  • expression (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The value forced onto the signal.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

property Expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the expression (_expression).

Returns:

The expression.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Target: SignalSymbol

Read-only property to access the target (_target).

Returns:

The target.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_expression: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

The expression held by this construct.

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_target: Symbol

Reference to the assignment’s destination.

class pyGHDL.dom.Sequential.SignalReleaseAssignment(assignmentNode, target, label=None)[source]

Inheritance

Inheritance diagram of SignalReleaseAssignment

Parameters:
__init__(assignmentNode, target, label=None)[source]

Initializes a signal release assignment.

Parameters:
  • target (SignalSymbol) – Reference to the assignment’s destination.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assignmentNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Target: SignalSymbol

Read-only property to access the target (_target).

Returns:

The target.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_target: Symbol

Reference to the assignment’s destination.

class pyGHDL.dom.Sequential.SequentialProcedureCall(callNode, procedureName, parameterAssociationItems, label=None)[source]

Inheritance

Inheritance diagram of SequentialProcedureCall

Parameters:
__init__(callNode, procedureName, parameterAssociationItems, label=None)[source]

Initializes a procedure call as a sequential statement.

Parameters:
  • procedureName (Symbol) – Reference to the called procedure.

  • parameterAssociationItems (Iterable[ParameterAssociationItem]) – List of all parameter associations of the call.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • callNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property ParameterAssociationItems: List[ParameterAssociationItem]

Read-only property to access the parameter association items (_parameterAssociationItems).

Returns:

List of parameter association items.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Procedure: Symbol

Read-only property to access the procedure (_procedure).

Returns:

The procedure.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parameterAssociationItems: List[ParameterAssociationItem]

List of all parameter associations of the call.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

_procedure: Symbol

Reference to the called procedure.

class pyGHDL.dom.Sequential.SequentialAssertStatement(assertNode, condition, message=None, severity=None, label=None)[source]

Inheritance

Inheritance diagram of SequentialAssertStatement

Parameters:
__init__(assertNode, condition, message=None, severity=None, label=None)[source]

Initializes a sequential assertion statement.

Parameters:
  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition guarding this statement.

  • message (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The reported message, or None if none was given.

  • severity (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The reported severity level, or None if none was given.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • assertNode (Iir)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property Message: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal | None

Read-only property to access the message (_message).

Returns:

The message, or None if not set.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Severity: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal | None

Read-only property to access the severity (_severity).

Returns:

The severity, or None if not set.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_label

The label of a model entity.

_message

The reported message, or None if none was given.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

_severity

The reported severity level, or None if none was given.

class pyGHDL.dom.Sequential.SequentialReportStatement(reportNode, message, severity=None, label=None)[source]

Inheritance

Inheritance diagram of SequentialReportStatement

Parameters:
__init__(reportNode, message, severity=None, label=None)[source]

Initializes a sequential report statement.

Parameters:
  • message (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The reported message, or None if none was given.

  • severity (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The reported severity level, or None if none was given.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • reportNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property Message: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal | None

Read-only property to access the message (_message).

Returns:

The message, or None if not set.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property Severity: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal | None

Read-only property to access the severity (_severity).

Returns:

The severity, or None if not set.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_label

The label of a model entity.

_message

The reported message, or None if none was given.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

_severity

The reported severity level, or None if none was given.

class pyGHDL.dom.Sequential.ReturnStatement(returnNode, returnValue=None, label=None)[source]

Inheritance

Inheritance diagram of ReturnStatement

Parameters:
__init__(returnNode, returnValue=None, label=None)[source]

Initializes a return statement.

Parameters:
  • returnValue (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The returned expression, or None for a procedure.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • returnNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property ReturnValue: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal | None

Read-only property to access the return value (_returnValue).

Returns:

The return value, or None if not set.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_label

The label of a model entity.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

_returnValue

The returned expression, or None for a procedure.

class pyGHDL.dom.Sequential.NullStatement(waitNode, label=None)[source]

Inheritance

Inheritance diagram of NullStatement

Parameters:
__init__(waitNode, label=None)[source]

Initializes a statement.

Parameters:
  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • waitNode (Iir)

Return type:

None

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_label: str | None

The label of a model entity.

_normalizedLabel: str | None

The normalized (lower case) label of a model entity.

_parent: ModelEntity

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.NextStatement(exitNode, condition=None, label=None)[source]

Inheritance

Inheritance diagram of NextStatement

Parameters:
__init__(exitNode, condition=None, label=None)[source]

Initializes a loop control statement.

Parameters:
  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition guarding this statement.

  • loopLabel – The label of the controlled loop, or None for the innermost loop.

  • parent – The parent model entity of this entity.

  • exitNode (Iir)

  • label (str)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property LoopReference: LoopStatement

Read-only property to access the loop reference (_loopReference).

Returns:

The loop reference.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_label

The label of a model entity.

_loopReference

Reference to the loop this statement controls.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.ExitStatement(exitNode, condition=None, label=None)[source]

Inheritance

Inheritance diagram of ExitStatement

Parameters:
__init__(exitNode, condition=None, label=None)[source]

Initializes a loop control statement.

Parameters:
  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition guarding this statement.

  • loopLabel – The label of the controlled loop, or None for the innermost loop.

  • parent – The parent model entity of this entity.

  • exitNode (Iir)

  • label (str)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property LoopReference: LoopStatement

Read-only property to access the loop reference (_loopReference).

Returns:

The loop reference.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_label

The label of a model entity.

_loopReference

Reference to the loop this statement controls.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

class pyGHDL.dom.Sequential.WaitStatement(waitNode, sensitivityList=None, condition=None, timeout=None, label=None)[source]

Inheritance

Inheritance diagram of WaitStatement

Parameters:
__init__(waitNode, sensitivityList=None, condition=None, timeout=None, label=None)[source]

Initializes a wait statement.

Parameters:
  • sensitivityList (Iterable[Symbol]) – List of all signal names to wait on, or None if none was given.

  • condition (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The condition guarding this statement.

  • timeout (BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal) – The timeout expression, or None if none was given.

  • label (str) – The label of a model entity.

  • parent – The parent model entity of this entity.

  • waitNode (Iir)

Return type:

None

property Condition: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the condition of a statement (_condition).

Returns:

The expression representing the condition of a statement.

GetAncestor(type)

Return the closest ancestor of the given type found by walking the parent chain upwards.

Iterates the parent chain - starting at this model entity - upwards (toward the root of the model) until an ancestor of the requested type is found.

Parameters:

type (Type) – Class (type) of the ancestor to find.

Return type:

ModelEntity

Returns:

The closest ancestor of the requested type.

Raises:

VHDLModelException – If the root of the model is reached without finding an ancestor of the requested type.

classmethod GetMethodsWithAttributes(predicate: TAttr | Iterable[TAttr] | None = None) Dict[Callable, Tuple[Attribute, ...]]
Parameters:

predicate (TypeVar(TAttr) | Iterable[TypeVar(TAttr)] | None) – An attribute class, an iterable of attribute classes, or None to accept every attribute.

Return type:

Dict[Callable, Tuple[Attribute, ...]]

Returns:

Dictionary of methods and the matching attributes attached to them.

Raises:
  • ValueError – If an element of parameter ‘predicate’ is not a sub-class of Attribute.

  • ValueError – If parameter ‘predicate’ is neither an attribute class nor an iterable of those.

property Label: str | None

Read-only property to access the model entity’s label (_label).

Returns:

Label of a model entity.

property NormalizedLabel: str | None

Read-only property to access the model entity’s normalized label (_normalizedLabel).

Returns:

Normalized label of a model entity.

property Parent: ModelEntity

Property to access the model entity’s parent element reference in a logical hierarchy (_parent).

Returns:

Reference to the parent entity.

property Position: <pyTooling.Decorators.readonly object at 0x7c526738b7d0>

Cached read-only property to access an IIR’s position in source code (_position).

If _position is None, resolve the position object from _iirNode

Returns:

The IIR’s position in the source file.

property SensitivityList: List[Symbol]

Read-only property to access the sensitivity list (_sensitivityList).

Returns:

List of sensitivity list.

property Timeout: BaseExpression | QualifiedExpression | FunctionCall | TypeConversion | Literal

Read-only property to access the timeout (_timeout).

Returns:

The timeout.

__getstate__() Dict[str, Any]

Helper for pickle.

Return type:

Dict[str, Any]

_condition

The condition guarding this statement.

_label

The label of a model entity.

_normalizedLabel

The normalized (lower case) label of a model entity.

_parent

Reference to a parent entity in the logical model hierarchy.

_sensitivityList

List of all signal names to wait on, or None if none was given.

_timeout

The timeout expression, or None if none was given.