@node-ctypes/winrt - v0.1.0
    Preparing search index...

    Function readVectorView

    • Read every element of a WinRT IVectorView<T> or IVector<T> (both share slots 6 GetAt and 7 get_Size) into a JavaScript array, releasing the view.

      Type Parameters

      • T

      Parameters

      • viewAddr: bigint
      • readElement: (
            view: InterfacePointer<
                ComInterfaceDef<
                    ComInterfaceDef<
                        ComInterfaceDef<
                            undefined,
                            readonly [
                                MethodSpec<
                                    "QueryInterface",
                                    RawFunction<
                                        SimpleCDataConstructor<"int32"> & {},
                                        readonly [
                                            PointerTypeDef<typeof GUID>,
                                            PointerTypeDef<SimpleCDataConstructor<(...)>>,
                                        ],
                                    >,
                                    "method",
                                    "QueryInterface",
                                >,
                                MethodSpec<
                                    "AddRef",
                                    RawFunction<SimpleCDataConstructor<"uint32">, readonly []>,
                                    "method",
                                    "AddRef",
                                >,
                                MethodSpec<
                                    "Release",
                                    RawFunction<SimpleCDataConstructor<"uint32">, readonly []>,
                                    "method",
                                    "Release",
                                >,
                            ],
                            readonly [],
                        >,
                        readonly [
                            MethodSpec<
                                "GetIids",
                                RawFunction<
                                    SimpleCDataConstructor<"int32"> & {},
                                    readonly [
                                        SimpleCDataConstructor<"pointer">,
                                        SimpleCDataConstructor<"pointer">,
                                    ],
                                >,
                                "method",
                                "GetIids",
                            >,
                            MethodSpec<
                                "GetRuntimeClassName",
                                RawFunction<
                                    SimpleCDataConstructor<"int32"> & {},
                                    readonly [SimpleCDataConstructor<"pointer">],
                                >,
                                "method",
                                "GetRuntimeClassName",
                            >,
                            MethodSpec<
                                "GetTrustLevel",
                                RawFunction<
                                    SimpleCDataConstructor<"int32"> & {},
                                    readonly [SimpleCDataConstructor<"pointer">],
                                >,
                                "method",
                                "GetTrustLevel",
                            >,
                        ],
                        readonly [],
                    >,
                    readonly [
                        MethodSpec<
                            "GetAt",
                            RawFunction<
                                SimpleCDataConstructor<"int32"> & {},
                                readonly [
                                    SimpleCDataConstructor<"uint32">,
                                    SimpleCDataConstructor<"pointer">,
                                ],
                            >,
                            "method",
                            "GetAt",
                        >,
                        MethodSpec<
                            "get_Size",
                            RawFunction<
                                SimpleCDataConstructor<"int32"> & {},
                                readonly [SimpleCDataConstructor<"pointer">],
                            >,
                            "method",
                            "get_Size",
                        >,
                        MethodSpec<
                            "IndexOf",
                            RawFunction<
                                SimpleCDataConstructor<"int32"> & {},
                                readonly [
                                    SimpleCDataConstructor<"pointer">,
                                    SimpleCDataConstructor<"pointer">,
                                    SimpleCDataConstructor<"pointer">,
                                ],
                            >,
                            "method",
                            "IndexOf",
                        >,
                        MethodSpec<
                            "GetMany",
                            RawFunction<
                                SimpleCDataConstructor<"int32"> & {},
                                readonly [
                                    SimpleCDataConstructor<"uint32">,
                                    SimpleCDataConstructor<"uint32">,
                                    SimpleCDataConstructor<"pointer">,
                                    SimpleCDataConstructor<"pointer">,
                                ],
                            >,
                            "method",
                            "GetMany",
                        >,
                    ],
                    readonly [],
                >,
            >,
            index: number,
        ) => T

      Returns T[]