FCIFlushCabinet function (fci.h)

The FCIFlushCabinet function completes the current cabinet.

Syntax

BOOL DIAMONDAPI FCIFlushCabinet(
  [in] HFCI                 hfci,
  [in] BOOL                 fGetNextCab,
  [in] PFNFCIGETNEXTCABINET pfnfcignc,
  [in] PFNFCISTATUS         pfnfcis
);

Parameters

[in] hfci

A valid FCI context handle returned by theFCICreate function.

[in] fGetNextCab

Specifies whether the function pointed to by the supplied GetNextCab parameter will be called.

[in] pfnfcignc

Pointer to an application-defined callback function to obtain specifications on the next cabinet to create. The function should be declared using the FNFCIGETNEXTCABINET macro.

[in] pfnfcis

Pointer to an application-defined callback function to update the user. The function should be declared using the FNFCISTATUS macro.

Return value

If the function succeeds, it returns TRUE; otherwise, FALSE.

Extended error information is provided in the ERF structure used to create the FCI context.

Remarks

The FCIFlushCabinet API forces the current cabinet under construction to be completed immediately and then written to disk. Further calls to FCIAddFile will result in files being added to another cabinet.

In the event the current cabinet has reached the application-specified media size limit, the pending data within an FCI's internal buffers will be placed into another cabinet.

The fGetNextCab flag determines whether the function pointed to by the GetNextCab parameter will be called. If fGetNextCab is set TRUE, GetNextCab is called to obtain continuation information. If FALSE, then GetNextCab is called only in the event the cabinet overflows.

Requirements

   
Target Platform Windows
Header fci.h
Library Cabinet.lib
DLL Cabinet.dll

See also

FCIFlushFolder