13 instantiations of MemoryHandle
Microsoft.AspNetCore.Server.HttpSys (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (1)
153return new MemoryHandle(((IntPtr)_memoryHandle.Value.Pointer + byteOffset).ToPointer(), default, this);
Microsoft.AspNetCore.Server.IIS (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (1)
153return new MemoryHandle(((IntPtr)_memoryHandle.Value.Pointer + byteOffset).ToPointer(), default, this);
Microsoft.AspNetCore.Server.Kestrel.Core (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (1)
153return new MemoryHandle(((IntPtr)_memoryHandle.Value.Pointer + byteOffset).ToPointer(), default, this);
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (1)
153return new MemoryHandle(((IntPtr)_memoryHandle.Value.Pointer + byteOffset).ToPointer(), default, this);
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (1)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (1)
153return new MemoryHandle(((IntPtr)_memoryHandle.Value.Pointer + byteOffset).ToPointer(), default, this);
System.Net.Security (1)
System\Net\Security\SslStream.cs (1)
1001return new MemoryHandle(_pointer + elementIndex, default, null);
System.Numerics.Tensors (1)
System\Numerics\Tensors\netcore\Tensor_1.cs (1)
211return new MemoryHandle(Unsafe.AsPointer(ref GetPinnableReference()), handle);
System.Private.CoreLib (6)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Memory.cs (3)
403return new MemoryHandle(Unsafe.AsPointer(ref stringData), handle); 415return new MemoryHandle(pointer); 422return new MemoryHandle(pointer, handle);
src\runtime\src\libraries\System.Private.CoreLib\src\System\ReadOnlyMemory.cs (3)
318return new MemoryHandle(Unsafe.AsPointer(ref stringData), handle); 330return new MemoryHandle(pointer); 337return new MemoryHandle(pointer, handle);
62 references to MemoryHandle
Microsoft.AspNetCore.Authentication.Negotiate (1)
Internal\NegotiateChannelBinding.cs (1)
17using var pinnedToken = channelBindingToken.Pin();
Microsoft.AspNetCore.Server.HttpSys (4)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (2)
24private MemoryHandle? _memoryHandle; 126public override MemoryHandle Pin(int byteOffset = 0)
src\aspnetcore\src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (2)
34private MemoryHandle _memoryHandle; 923public override MemoryHandle Pin(int elementIndex = 0)
Microsoft.AspNetCore.Server.IIS (10)
Core\IO\AsyncIOEngine.Read.cs (1)
15private MemoryHandle _inputHandle;
Core\IO\AsyncWriteOperationBase.cs (4)
16private MemoryHandle[]? _handles; 64foreach (var handle in _handles) 103_handles = new MemoryHandle[nChunks]; 108ref var handle = ref _handles[currentChunk];
Core\IO\WebSocketsAsyncIOEngine.Read.cs (1)
30private MemoryHandle _inputHandle;
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (2)
24private MemoryHandle? _memoryHandle; 126public override MemoryHandle Pin(int byteOffset = 0)
src\aspnetcore\src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (2)
34private MemoryHandle _memoryHandle; 923public override MemoryHandle Pin(int elementIndex = 0)
Microsoft.AspNetCore.Server.Kestrel.Core (2)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (2)
24private MemoryHandle? _memoryHandle; 126public override MemoryHandle Pin(int byteOffset = 0)
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes (2)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (2)
24private MemoryHandle? _memoryHandle; 126public override MemoryHandle Pin(int byteOffset = 0)
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (2)
src\aspnetcore\src\Shared\Buffers.MemoryPool\DiagnosticPoolBlock.cs (2)
24private MemoryHandle? _memoryHandle; 126public override MemoryHandle Pin(int byteOffset = 0)
Microsoft.Extensions.Caching.Hybrid.Tests (1)
DistributedCacheTests.cs (1)
379public override MemoryHandle Pin(int elementIndex = 0) => throw new NotSupportedException();
mscorlib (1)
mscorlib.cs (1)
38[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Buffers.MemoryHandle))]
netstandard (1)
netstandard.cs (1)
66[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Buffers.MemoryHandle))]
System.Formats.Cbor (1)
src\runtime\src\libraries\Common\src\System\Memory\PointerMemoryManager.cs (1)
26public override MemoryHandle Pin(int elementIndex = 0)
System.IO.Compression (6)
src\runtime\src\libraries\Common\src\Microsoft\Win32\SafeHandles\SafeZstdHandle.cs (4)
15internal MemoryHandle? _prefixHandle; 55MemoryHandle handle = prefix.Pin(); 90internal MemoryHandle? _prefixHandle; 130MemoryHandle handle = prefix.Pin();
System\IO\Compression\DeflateZLib\Deflater.cs (1)
18private MemoryHandle _inputBufferHandle;
System\IO\Compression\DeflateZLib\Inflater.cs (1)
23private MemoryHandle _inputBufferHandle; // The handle to the buffer that provides input to _zlibStream
System.Memory (1)
src\runtime\artifacts\obj\System.Memory\Release\net11.0\System.Memory.Forwards.cs (1)
6[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Buffers.MemoryHandle))]
System.Net.Security (1)
System\Net\Security\SslStream.cs (1)
998public override MemoryHandle Pin(int elementIndex = 0)
System.Net.WebSockets.Client (6)
System\Net\WebSockets\BrowserWebSockets\BrowserInterop.cs (3)
72MemoryHandle responseHandle) 89public static unsafe Task? UnsafeSend(JSObject jsWs, MemoryHandle pinBuffer, int length, WebSocketMessageType messageType, bool endOfMessage) 100public static unsafe Task? ReceiveUnsafe(JSObject jsWs, MemoryHandle pinBuffer, int length)
System\Net\WebSockets\BrowserWebSockets\BrowserWebSocket.cs (3)
30private MemoryHandle? responseStatusHandle; 373MemoryHandle? pinBuffer = null; 424MemoryHandle? pinBuffer = null;
System.Numerics.Tensors (3)
System\Numerics\Tensors\netcore\Tensor_1.cs (3)
206/// <summary>Pins and gets a <see cref="MemoryHandle"/> to the backing memory.</summary> 207/// <returns><see cref="MemoryHandle"/></returns> 208public unsafe MemoryHandle GetPinnedHandle()
System.Private.CoreLib (15)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\IPinnable.cs (2)
15/// <param name="elementIndex">The offset to the element within the memory at which the returned <see cref="MemoryHandle"/> points to.</param> 16MemoryHandle Pin(int elementIndex);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Buffers\MemoryManager.cs (2)
26/// <param name="elementIndex">The offset to the element within the memory at which the returned <see cref="MemoryHandle"/> points to. (default = 0)</param> 27public abstract MemoryHandle Pin(int elementIndex = 0);
src\runtime\src\libraries\System.Private.CoreLib\src\System\IO\RandomAccess.Unix.cs (7)
60MemoryHandle[] handles = new MemoryHandle[buffers.Count]; 70MemoryHandle memoryHandle = buffer.Pin(); 95foreach (MemoryHandle memoryHandle in handles) 183var handles = new MemoryHandle[buffersCount]; 196MemoryHandle memoryHandle = buffer.Pin(); 263foreach (MemoryHandle memoryHandle in handles)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Memory.cs (2)
376/// The GC will not move the memory until the returned <see cref="MemoryHandle"/> 382public unsafe MemoryHandle Pin()
src\runtime\src\libraries\System.Private.CoreLib\src\System\ReadOnlyMemory.cs (2)
298/// The GC will not move the memory until the returned <see cref="MemoryHandle"/> 304public unsafe MemoryHandle Pin()
System.Runtime (1)
src\runtime\artifacts\obj\System.Runtime\Release\net11.0\System.Runtime.Forwards.cs (1)
57[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Buffers.MemoryHandle))]
System.Security.Cryptography (2)
src\runtime\src\libraries\Common\src\System\IO\MemoryMappedFiles\MemoryMappedFileMemoryManager.cs (1)
84public override MemoryHandle Pin(int elementIndex = 0)
src\runtime\src\libraries\Common\src\System\Memory\PointerMemoryManager.cs (1)
26public override MemoryHandle Pin(int elementIndex = 0)
System.Security.Cryptography.Cose (1)
src\runtime\src\libraries\Common\src\System\Memory\PointerMemoryManager.cs (1)
26public override MemoryHandle Pin(int elementIndex = 0)
System.Security.Cryptography.Pkcs (1)
src\runtime\src\libraries\Common\src\System\Memory\PointerMemoryManager.cs (1)
26public override MemoryHandle Pin(int elementIndex = 0)