QueryCompressorInformation function

Queries a compressor for information for a particular compression algorithm.

Syntax

BOOL QueryCompressorInformation(
  COMPRESSOR_HANDLE          CompressorHandle,
  COMPRESS_INFORMATION_CLASS CompressInformationClass,
  PVOID                      CompressInformation,
  SIZE_T                     CompressInformationSize
);

Parameters

CompressorHandle

Handle to the compressor being queried for information.

CompressInformationClass

A value of the COMPRESS_INFORMATION_CLASS enumeration that identifies the type of information.

CompressInformation

Information for the compression algorithm written as bytes. The maximum size in bytes of this information is given by CompressInformationSize.

CompressInformationSize

Maximum size in bytes of the information.

Return value

If the function succeeds, the return value is nonzero. If the function fails, the return value is zero. To get extended error information, call GetLastError.

Remarks

If the compression algorithm fails for some internal reason, the error from GetLastError can be ERROR_FUNCTION_FAILED. If the system cannot locate the compression algorithm handle, the error can be ERROR_INVALID_HANDLE. If the compression algorithm does not allow the information class, the error can be ERROR_UNSUPPORTED_TYPE. If the buffer is to small to hold the value, the error can be ERROR_INSUFFICIENT_BUFFER.

Requirements

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

See also

Compression API Functions