/*++

Copyright (c) 1998-1999 Microsoft Corporation

Module Name:

    poolapi.h

Abstract:

    Public header file for pool extension APIs.

Author:

    Ted Miller (tedm) 13 Jan 1998

Revision History:

--*/

#ifndef _INC_POOLAPI
#define _INC_POOLAPI

//
// Get the data structures.
//
#include "poolext.h"

//
// Define API decoration for direct importing of DLL references.
//
#if !defined (_POOLAPI_)
#define POOLEXTAPI DECLSPEC_IMPORT
#else
#define POOLEXTAPI
#endif


POOLEXTAPI
BOOL
WINAPI
PoolAreEnhancementsPresent(
    IN  CONST VOID *Reserved,
    OUT PBOOL Present,
    OUT PWORD DriverMajorVersion,
    OUT PWORD DriverMinorVersion,
    OUT PWORD DllMajorVersion,
    OUT PWORD DllMinorVersion
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtGetModuleList(
    IN  CONST VOID *Reserved,
    IN  ULONG32 BufferSize,
    OUT PPOOLEXT_MODULE Modules,    OPTIONAL
    OUT PULONG32 ModuleCount
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtSetBlockTracking(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName,          OPTIONAL
    IN ULONG32 Tag,                 OPTIONAL
    IN PoolTrackType TrackingType
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtRemoveBlockTracking(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName,          OPTIONAL
    IN ULONG32 Tag                  OPTIONAL
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtSetTailCheckingFailureOperation(
    IN CONST VOID *Reserved,
    IN ULONG32 Operations
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtQueryStatistics(
    IN  CONST VOID *Reserved,
    IN  LPCWSTR ModuleName,         OPTIONAL
    OUT PPOOLEXT_STATISTICS Statistics
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtResetStatistics(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName           OPTIONAL
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtQueryConfiguration(
    IN  CONST VOID *Reserved,
    IN  LPCWSTR ModuleName,         OPTIONAL
    OUT PPOOLEXT_CONFIGURATION Buffer,
    IN  ULONG32 BufferSize,
    OUT PULONG32 BytesReturned      OPTIONAL
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtSetConfiguration(
    IN CONST VOID *Reserved,
    IN PPOOLEXT_CONFIGURATION Configuration
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtMakeStatePersistent(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName           OPTIONAL
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtErasePersistedState(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName           OPTIONAL
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtEnable(
    IN CONST VOID *Reserved
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtDisable(
    IN CONST VOID *Reserved
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtSetLogging(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName,          OPTIONAL
    IN PoolLogType LogType,
    UINT_PTR Spare
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtSetFreeBlockFill(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName,          OPTIONAL
    IN PoolFillType FillType,
    IN ULONG32 Pattern,
    IN SIZE_T MaxFillLength,        OPTIONAL
    UINT_PTR Spare
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtQueryConfigurationEx(
    IN CONST VOID *Reserved,
    IN LPCWSTR ModuleName,              OPTIONAL
    OUT PPOOLEXT_CONFIGURATION_EX Buffer,
    IN ULONG32 BufferSize,
    OUT PULONG32 BytesReturned          OPTIONAL
    );

POOLEXTAPI
BOOL
WINAPI
PoolExtSetConfigurationEx(
    IN PVOID Reserved,
    IN PPOOLEXT_CONFIGURATION_EX Configuration
    );

#endif // _INC_POOLAPI
