Table of Contents

Class ArrayType

Namespace
ICSharpCode.Decompiler.TypeSystem
Assembly
ICSharpCode.Decompiler.dll

Represents an array type.

public sealed class ArrayType : TypeWithElementType, IType, INamedElement, IEquatable<IType>, ICompilationProvider
Inheritance
ArrayType
Implements
Inherited Members
Extension Methods

Constructors

ArrayType(ICompilation, IType, int, Nullability)

public ArrayType(ICompilation compilation, IType elementType, int dimensions = 1, Nullability nullability = Nullability.Oblivious)

Parameters

compilation ICompilation
elementType IType
dimensions int
nullability Nullability

Properties

Compilation

Gets the parent compilation. This property never returns null.

public ICompilation Compilation { get; }

Property Value

ICompilation

Dimensions

public int Dimensions { get; }

Property Value

int

DirectBaseTypes

public override IEnumerable<IType> DirectBaseTypes { get; }

Property Value

IEnumerable<IType>

IsReferenceType

public override bool? IsReferenceType { get; }

Property Value

bool?

Kind

Gets the type kind.

public override TypeKind Kind { get; }

Property Value

TypeKind

NameSuffix

public override string NameSuffix { get; }

Property Value

string

Nullability

Gets the nullability annotation on this type.

public override Nullability Nullability { get; }

Property Value

Nullability

Methods

AcceptVisitor(TypeVisitor)

public override IType AcceptVisitor(TypeVisitor visitor)

Parameters

visitor TypeVisitor

Returns

IType

ChangeNullability(Nullability)

Creates a new type that is a copy of this type, with the changed nullability annotation.

public override IType ChangeNullability(Nullability nullability)

Parameters

nullability Nullability

Returns

IType

Equals(IType)

public override bool Equals(IType other)

Parameters

other IType

Returns

bool

GetAccessors(Predicate<IMethod>, GetMemberOptions)

public override IEnumerable<IMethod> GetAccessors(Predicate<IMethod> filter = null, GetMemberOptions options = GetMemberOptions.None)

Parameters

filter Predicate<IMethod>
options GetMemberOptions

Returns

IEnumerable<IMethod>

GetHashCode()

public override int GetHashCode()

Returns

int

GetMethods(IReadOnlyList<IType>, Predicate<IMethod>, GetMemberOptions)

public override IEnumerable<IMethod> GetMethods(IReadOnlyList<IType> typeArguments, Predicate<IMethod> filter = null, GetMemberOptions options = GetMemberOptions.None)

Parameters

typeArguments IReadOnlyList<IType>
filter Predicate<IMethod>
options GetMemberOptions

Returns

IEnumerable<IMethod>

GetMethods(Predicate<IMethod>, GetMemberOptions)

public override IEnumerable<IMethod> GetMethods(Predicate<IMethod> filter = null, GetMemberOptions options = GetMemberOptions.None)

Parameters

filter Predicate<IMethod>
options GetMemberOptions

Returns

IEnumerable<IMethod>

GetProperties(Predicate<IProperty>, GetMemberOptions)

public override IEnumerable<IProperty> GetProperties(Predicate<IProperty> filter = null, GetMemberOptions options = GetMemberOptions.None)

Parameters

filter Predicate<IProperty>
options GetMemberOptions

Returns

IEnumerable<IProperty>

ToString()

public override string ToString()

Returns

string

VisitChildren(TypeVisitor)

public override IType VisitChildren(TypeVisitor visitor)

Parameters

visitor TypeVisitor

Returns

IType