ZLab.Discrete ZLab.Discrete
ZLab.Discrete ZLab.Discrete
Developed by Zeke Zhang

Search Results for

    Edit this page

    Method GetReadOnlyMemory

    | Edit this page View Source

    GetReadOnlyMemory()

    Gets a read-only memory representation of the underlying buffer storing the grid values.

    Declaration
    public ReadOnlyMemory<T> GetReadOnlyMemory()
    Returns
    Type Description
    ReadOnlyMemory<T>
    Implements
    IGrid<T>.GetReadOnlyMemory()
    Remarks

    Use this if you need to pass the grid data to APIs that require ReadOnlyMemory, such as asynchronous methods or APIs that work with memory buffers. For most use cases, GetReadOnlyBuffer() or GetBuffer() will be more efficient for direct access to the grid data.