Class SzArrayTypeSignature
- Namespace
- AsmResolver.DotNet.Signatures
- Assembly
- AsmResolver.DotNet.dll
Represents a type signature describing a single dimension array with 0 as a lower bound.
public class SzArrayTypeSignature : ArrayBaseTypeSignature, ITypeDescriptor, IMemberDescriptor, IFullNameProvider, INameProvider, IModuleProvider, IImportable
- Inheritance
-
SzArrayTypeSignature
- Implements
- Inherited Members
- Extension Methods
Constructors
SzArrayTypeSignature(TypeSignature)
Creates a new single-dimension array signature with 0 as a lower bound.
public SzArrayTypeSignature(TypeSignature baseType)
Parameters
baseTypeTypeSignatureThe type of the elements to store in the array.
Properties
ElementType
Gets the element type of the
public override ElementType ElementType { get; }
Property Value
Name
Gets the name of the object.
public override string Name { get; }
Property Value
Rank
Gets the number of dimensions this array defines.
public override int Rank { get; }
Property Value
Methods
AcceptVisitor<TResult>(ITypeSignatureVisitor<TResult>)
Visit the current type signature using the provided visitor.
public override TResult AcceptVisitor<TResult>(ITypeSignatureVisitor<TResult> visitor)
Parameters
visitorITypeSignatureVisitor<TResult>The visitor to accept.
Returns
- TResult
The result the visitor produced after visiting this type signature.
Type Parameters
TResultThe type of result the visitor produces.
AcceptVisitor<TState, TResult>(ITypeSignatureVisitor<TState, TResult>, TState)
Visit the current type signature using the provided visitor.
public override TResult AcceptVisitor<TState, TResult>(ITypeSignatureVisitor<TState, TResult> visitor, TState state)
Parameters
visitorITypeSignatureVisitor<TState, TResult>The visitor to accept.
stateTStateAdditional state.
Returns
- TResult
The result the visitor produced after visiting this type signature.
Type Parameters
TStateThe type of additional state.
TResultThe type of result the visitor produces.
GetDimensions()
Obtains the dimensions this array defines.
public override IEnumerable<ArrayDimension> GetDimensions()
Returns
- IEnumerable<ArrayDimension>
The dimensions.
GetDirectBaseClass()
Obtains the direct base class of the type signature.
public override TypeSignature? GetDirectBaseClass()
Returns
- TypeSignature
The type representing the immediate base class.
Remarks
The direct base class is computed according to the rules defined in ECMA-335 I.8.7, where interfaces will extend object, and generic base types will be instantiated with the derived classes type arguments (if any).