Jump to content

Template:VIServerGetAncestors: Difference between revisions

From LabVIEW Wiki
Starting Templates
(No difference)

Revision as of 04:44, 1 September 2019


Usage

The input to this template is the Class ID of a class in the VI Server Class Hierarchy. The template then builds the class's inheritance hierarchy through a series of nested if-statements using the Template:VIServerGetParent template. The current limit of nested if-statements is nine (9). Currently, as of LabVIEW 2019, the VI Server Class Hierarchy is only six (6) levels deep, at the deepest.

Syntax is as follows:

{{VIServerGetAncestors|{{{1}}}}}

where:

Parameter Description Default
{{{1}}} The Class ID of a class in the VI Server Class Hierarchy.

Example: Class with a Parent

{{VIServerGetAncestors|36}}

Result:

36 is the Class ID of GObject class, whose Parent Class is Generic class, whose Class ID is 3.

Example: Class without a Parent

{{VIServerGetAncestors|1}}

Result:

1 is the Class ID of Application class, which is a top-level class and does not have a Parent Class.

See Also