In This Article

FunctionDeclaration Class

An AST node for a function declaration.

public class FunctionDeclaration : DeclarationBase, IAstNode
Inheritance:
object AstNodeBase Statement DeclarationBase object
Implements:
IAstNode

Remarks

This type was generated by the Actipro Language Designer tool v26.1.0 (http://www.actiprosoftware.com).

Constructors

FunctionDeclaration()

Initializes an instance of the class.

public FunctionDeclaration()

Properties

DeclaringClass

The declaring class, if the function is a method.

public ClassDeclaration? DeclaringClass { get; }

Property Value

ClassDeclaration

HasParameters

Indicates whether the Parameters collection property contains at least one item.

public bool HasParameters { get; }

Property Value

bool:

true if there is at least one item in the collection; otherwise, false.

Id

An integer value that identifies the type of AST node, if known.

public override int Id { get; }

Property Value

int

Remarks

This class' default implementation always returns 0.

IsAsync

The is async.

public bool IsAsync { get; set; }

Property Value

bool

IsClassMethod

Indicate whether this definition is a class method.

public bool IsClassMethod { get; }

Property Value

bool

IsMethod

Indicates whether this definition is a method.

public bool IsMethod { get; }

Property Value

bool

IsStaticMethod

Indicates whether this definition is a static method.

public bool IsStaticMethod { get; }

Property Value

bool

Parameters

The collection of parameters.

public IList<Parameter> Parameters { get; }

Property Value

IList<Parameter>

ReturnAnnotationExpression

The return annotation expression.

public Expression? ReturnAnnotationExpression { get; set; }

Property Value

Expression

Methods

GetChildrenEnumerator()

Retrieves an IEnumerator object that can iterate the child IAstNode objects in this node.

protected override IEnumerator<IAstNode>? GetChildrenEnumerator()

Returns

IEnumerator<IAstNode>

Inherited Members

Extension Methods