Table of Contents

Class CodeElement<T>

Namespace
SunamoRoslyn.Data
Assembly
SunamoRoslyn.dll

Represents a code element with a name, type, position information, and syntax member reference.

public class CodeElement<T>

Type Parameters

T

The type of the code element classification.

Inheritance
CodeElement<T>
Derived
Inherited Members
Extension Methods

Properties

From

Gets or sets the start index in the document.

public int From { get; set; }

Property Value

int

Index

Gets or sets the index of this code element within its parent collection.

public int Index { get; set; }

Property Value

int

Length

Gets or sets the length of this code element.

public int Length { get; set; }

Property Value

int

Member

Gets or sets the member declaration syntax node. Base classes of MemberDeclarationSyntax are only CSharpSyntaxNode and SyntaxNode.

public MemberDeclarationSyntax? Member { get; set; }

Property Value

MemberDeclarationSyntax

Name

Gets or sets the name. Setting this also updates NameWithoutGeneric.

public string Name { get; set; }

Property Value

string

NameWithoutGeneric

Gets or sets the name without generic type parameters.

public string NameWithoutGeneric { get; set; }

Property Value

string

To

Gets or sets the end index in the document (last character position).

public int To { get; set; }

Property Value

int

Type

Gets or sets the classification type of this code element.

public T Type { get; set; }

Property Value

T