In This Article

MethodDeclaration Class

An AST node for a method declaration.

public class MethodDeclaration : TypeMemberDeclaration, IDecoratedMember, INamedTypeMember, IAstNode
Inheritance:
object AstNodeBase TypeMemberDeclaration object
Implements:
IDecoratedMember INamedTypeMember IAstNode

Remarks

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

Constructors

MethodDeclaration()

Initializes an instance of the class.

public MethodDeclaration()

Properties

Body

The body.

public MethodBody? Body { get; set; }

Property Value

MethodBody

Handles

The collection of handles.

public IList<QualifiedName> Handles { get; }

Property Value

IList<QualifiedName>

HasHandles

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

public bool HasHandles { get; }

Property Value

bool:

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

HasImplements

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

public bool HasImplements { get; }

Property Value

bool:

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

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.

HasTypeParameters

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

public bool HasTypeParameters { 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.

Implements

The collection of implements.

public IList<QualifiedName> Implements { get; }

Property Value

IList<QualifiedName>

Kind

A TypeMemberDeclarationKind indicating the kind of type member.

public override sealed TypeMemberDeclarationKind Kind { get; }

Property Value

TypeMemberDeclarationKind

Name

The name.

public SimpleName? Name { get; set; }

Property Value

SimpleName

Parameters

The collection of parameters.

public IList<ParameterDeclaration> Parameters { get; }

Property Value

IList<ParameterDeclaration>

ReturnType

The return type.

public ReturnTypeDeclaration? ReturnType { get; set; }

Property Value

ReturnTypeDeclaration

TypeParameters

The collection of type parameters.

public IList<TypeParameter> TypeParameters { get; }

Property Value

IList<TypeParameter>

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