Mallard
Search Results for

    Show / Hide Table of Contents

    Struct DuckDbStruct

    .NET representation of an instance of a structure type from DuckDB, where the member values are boxed.

    Implements
    ITuple
    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    ValueType.ToString()
    object.Equals(object, object)
    object.GetType()
    object.ReferenceEquals(object, object)
    Namespace: Mallard.Types
    Assembly: Mallard.dll
    Syntax
    public readonly struct DuckDbStruct : ITuple
    Remarks

    This representation is inefficient because of the boxing, but avoids generics (of arbitrary arity).

    Instances of this type are intended to be immutable (once created), but if the type of a member is a reference type, or a mutable value type (i.e. not readonly in C#), user code may be able to mutate the member value through the object reference that is made available (even in safe code). It is, obviously, highly discouraged to do so, but no direct memory corruption will occur should that be attempted.

    Properties

    | Edit this page View Source

    this[int]

    Get a member of the structure by its index.

    Declaration
    public object? this[int index] { get; }
    Parameters
    Type Name Description
    int index

    The index of the member, in the range from 0 (inclusive) to Length (exclusive).

    Property Value
    Type Description
    object

    The value of the member, boxed/casted to object.

    | Edit this page View Source

    Length

    The number of members in the structure.

    Declaration
    public int Length { get; }
    Property Value
    Type Description
    int

    Methods

    | Edit this page View Source

    ToImmutableArray()

    Get the values of the members of the structure as an immutable array of boxed objects.

    Declaration
    public ImmutableArray<object?> ToImmutableArray()
    Returns
    Type Description
    ImmutableArray<object>

    Implements

    ITuple
    • Edit this page
    • View Source
    In this article
    Back to top Generated by DocFX