protected override void Dispose(bool disposing) { if (disposing && !IsDisposed) { Close(true); PrivateOptions.Dispose(); } base.Dispose(disposing); }
private void Configure(IntPtr aioPtr) { PrivateOptions.SetSetters( x => __SetTimeoutDurationMilliseconds(_aioPtr, x) ); // TODO: TBD: perhaps we can run direct through the C calling conventions. _free = () => __Free(aioPtr); _wait = () => __Wait(aioPtr); _stop = () => __Stop(aioPtr); _cancel = () => __Cancel(aioPtr); _getResult = () => __GetResult(aioPtr); _getMessagePtr = () => __GetMessagePtr(aioPtr); _setMessagePtr = msgPtr => __SetMessagePtr(aioPtr, msgPtr); }