MonoLibUsb.Profile.MonoUsbProfileHandle.ReleaseHandle C# (CSharp) Method

ReleaseHandle() protected method

When overridden in a derived class, executes the code required to free the handle.
protected ReleaseHandle ( ) : bool
return bool
        protected override bool ReleaseHandle()
        {
            lock (oDeviceProfileRefLock)
            {
                if (!IsInvalid)
                {
                    MonoUsbApi.UnrefDevice(handle);
                    mDeviceProfileRefCount--;
                    SetHandleAsInvalid();
                    Debug.Print(GetType().Name + " : ReleaseHandle #{0}", mDeviceProfileRefCount);
                }
                return true;
            }
        }