libusbK.HotK.HotK C# (CSharp) Method

HotK() public method

public HotK ( KHOT_PARAMS &InitParams ) : System
InitParams KHOT_PARAMS
return System
        public HotK(ref KHOT_PARAMS InitParams)
        {
            RuntimeHelpers.PrepareConstrainedRegions();

            try
            {
            }
            finally
            {
                bool success = Functions.HotK_Init(out handle, ref InitParams);

                if (!success || handle.IsInvalid || handle.IsClosed)
                {
                    handle.SetHandleAsInvalid();
                    int errorCode = Marshal.GetLastWin32Error();
                    throw new Exception(GetType().Name + " failed. ErrorCode=" + errorCode.ToString("X"));
                }
            }
        }