Show / Hide Table of Contents

    Struct TypeSpecifier

    Description of a type specifier, that indicates whether a type is an array, pointer or reference.

    Implements
    IEquatable<TypeSpecifier>
    Inherited Members
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Namespace: Alphaleonis.Reflection.Metadata
    Assembly: Alphaleonis.Reflection.Metadata.dll
    Syntax
    public struct TypeSpecifier : IEquatable<TypeSpecifier>

    Fields

    | Improve this Doc View Source

    Pointer

    Indicates a pointer specifier in a type name, i.e. '*'.

    Declaration
    public static readonly TypeSpecifier Pointer
    Field Value
    Type Description
    TypeSpecifier
    | Improve this Doc View Source

    Reference

    Indicates a reference specifier in a type name, i.e. '&'.

    Declaration
    public static readonly TypeSpecifier Reference
    Field Value
    Type Description
    TypeSpecifier

    Properties

    | Improve this Doc View Source

    ArrayRank

    Gets the array rank if this indicates an array, or 0 otherwise.

    Declaration
    public int ArrayRank { get; }
    Property Value
    Type Description
    Int32

    The array rank.

    | Improve this Doc View Source

    Kind

    Gets the type of this specifier.

    Declaration
    public TypeSpecifierKind Kind { get; }
    Property Value
    Type Description
    TypeSpecifierKind

    Methods

    | Improve this Doc View Source

    Array(Int32)

    Indicates an array specifier in a type name, i.e. '[]', or '[,,]' etc.

    Declaration
    public static TypeSpecifier Array(int rank)
    Parameters
    Type Name Description
    Int32 rank

    The rank of the array. Must be greater than 0.

    Returns
    Type Description
    TypeSpecifier
    | Improve this Doc View Source

    Equals(TypeSpecifier)

    Tests if this TypeSpecifier is considered equal to another.

    Declaration
    public bool Equals(TypeSpecifier other)
    Parameters
    Type Name Description
    TypeSpecifier other

    The type specifier to compare to this object.

    Returns
    Type Description
    Boolean

    True if the objects are considered equal, false if they are not.

    | Improve this Doc View Source

    Equals(Object)

    Tests if this object is considered equal to another.

    Declaration
    public override bool Equals(object obj)
    Parameters
    Type Name Description
    Object obj

    The object to compare to this object.

    Returns
    Type Description
    Boolean

    True if the objects are considered equal, false if they are not.

    Overrides
    ValueType.Equals(Object)
    | Improve this Doc View Source

    GetHashCode()

    Calculates a hash code for this object.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    Int32

    A hash code for this object.

    Overrides
    ValueType.GetHashCode()
    | Improve this Doc View Source

    ToString()

    Convert this object into a string representation.

    Declaration
    public override string ToString()
    Returns
    Type Description
    String

    A string that represents this object.

    Overrides
    ValueType.ToString()

    Implements

    System.IEquatable<T>
    • Improve this Doc
    • View Source
    Back to top Copyright © 2018 Peter Palotas