System.Threading.ThreadPoolBoundHandle.AllocateNativeOverlapped C# (CSharp) Метод

AllocateNativeOverlapped() приватный Метод

private AllocateNativeOverlapped ( System preAllocated ) : System.Threading.NativeOverlapped*
preAllocated System
Результат System.Threading.NativeOverlapped*
        public unsafe System.Threading.NativeOverlapped* AllocateNativeOverlapped(System.Threading.PreAllocatedOverlapped preAllocated)
        {
            throw null;
        }

Same methods

ThreadPoolBoundHandle::AllocateNativeOverlapped ( IOCompletionCallback callback, object state, object pinData ) : NativeOverlapped*
ThreadPoolBoundHandle::AllocateNativeOverlapped ( PreAllocatedOverlapped preAllocated ) : NativeOverlapped*
ThreadPoolBoundHandle::AllocateNativeOverlapped ( System callback, object state, object pinData ) : System.Threading.NativeOverlapped*

Usage Example

Пример #1
0
 private Interop.HttpApi.HTTP_REQUEST* Allocate(ThreadPoolBoundHandle boundHandle, uint size)
 {
     uint newSize = size != 0 ? size : RequestBuffer == null ? 4096 : Size;
     if (_nativeOverlapped != null && newSize != RequestBuffer.Length)
     {
         NativeOverlapped* nativeOverlapped = _nativeOverlapped;
         _nativeOverlapped = null;
         _boundHandle.FreeNativeOverlapped(nativeOverlapped);
     }
     if (_nativeOverlapped == null)
     {
         SetBuffer(checked((int)newSize));
         _boundHandle = boundHandle;
         _nativeOverlapped = boundHandle.AllocateNativeOverlapped(ListenerAsyncResult.IOCallback, state: _result, pinData: RequestBuffer);
         return (Interop.HttpApi.HTTP_REQUEST*)Marshal.UnsafeAddrOfPinnedArrayElement(RequestBuffer, 0);
     }
     return RequestBlob;
 }
All Usage Examples Of System.Threading.ThreadPoolBoundHandle::AllocateNativeOverlapped