FbwfCacheThresholdNotification (fbwflib)
Last changed: anonymous

.
Summary
Signals an event when the available write cache falls below a specified size.

C# Signature:

[DllImport("fbwflib.dll", SetLastError=true)]
[return: MarshalAs(UnmanagedType.U4)]
static extern uint FbwfCacheThresholdNotification(
     UInt32 threshold,
     SafeHandle handle
);

VB Signature:

Declare Function FbwfCacheThresholdNotification Lib "fbwflib.dll" (TODO) As TODO

User-Defined Types:

None.

Alternative Managed API:

Do you know one? Please contribute it!

Notes:

Code is tested on Windows Embedded Standard 7 32bit.

Tips & Tricks:

The API defines an Void-Pointer as a parameter. The pointer must point to a function with 4 parameters itself. The parameters are the same as a WaitHandle with its initial state set to false. So you can use the SafeHandle of the ResetEvent class.

For more infos visit http://www.codeproject.com/Questions/1074408/How-to-use-the-fbwf-function-FbwfCacheThresholdNot

Sample Code:

_manualResetEvent = new ManualResetEvent(false);
NativeMethods.FbwfCacheThresholdNotification((uint)100, _manualResetEvent.SafeWaitHandle);

Documentation