OrtExternalMemoryHandle class final

\brief Base struct for imported external memory handles.

EPs derive from this struct to add EP-specific fields (e.g., CUdeviceptr for CUDA). EP is responsible for creating and releasing instances of the derived type.

Example derived type for CUDA EP: \code struct MyCudaExternalMemoryHandle : OrtExternalMemoryHandle { CUexternalMemory ext_memory; CUdeviceptr mapped_ptr; bool is_dedicated; }; \endcode

\since Version 1.24.

Inheritance
Implemented types
Available extensions

Constructors

OrtExternalMemoryHandle()

Properties

address Pointer<T>

Available on T, provided by the StructAddress extension

The memory address of the underlying data.
no setter
descriptor OrtExternalMemoryDescriptor
< External memory descriptor
getter/setter pair
ep_device Pointer<OrtEpDevice>
< EP device that created this handle
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
Release Pointer<NativeFunction<Void Function(Pointer<OrtExternalMemoryHandle> handle)>>
\brief Release callback for this handle. EP sets this to its release function.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
version int
< Must be ORT_API_VERSION
getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited