windows-nt/Source/XPSP1/NT/base/efiutil/efilib/inc/rcache.hxx

89 lines
1.6 KiB
C++
Raw Normal View History

2020-09-26 03:20:57 -05:00
/*++
Copyright (c) 1992 Microsoft Corporation
Module Name:
rcache.hxx
Abstract:
This class models a read cache of equal sized blocks.
--*/
#if !defined(_READ_CACHE_DEFN_)
#define _READ_CACHE_DEFN_
#include "dcache.hxx"
#include "cache.hxx"
#if defined ( _AUTOCHECK_ ) || defined( _EFICHECK_ )
#define IFSUTIL_EXPORT
#elif defined ( _IFSUTIL_MEMBER_ )
#define IFSUTIL_EXPORT __declspec(dllexport)
#else
#define IFSUTIL_EXPORT __declspec(dllimport)
#endif
DECLARE_CLASS(READ_CACHE);
class READ_CACHE : public DRIVE_CACHE {
public:
IFSUTIL_EXPORT
DECLARE_CONSTRUCTOR( READ_CACHE );
VIRTUAL
~READ_CACHE(
);
NONVIRTUAL
IFSUTIL_EXPORT
BOOLEAN
Initialize(
IN OUT PIO_DP_DRIVE Drive,
IN ULONG NumberOfCacheBlocks
);
VIRTUAL
BOOLEAN
Read(
IN BIG_INT StartingSector,
IN SECTORCOUNT NumberOfSectors,
OUT PVOID Buffer
);
VIRTUAL
BOOLEAN
Write(
IN BIG_INT StartingSector,
IN SECTORCOUNT NumberOfSectors,
IN PVOID Buffer
);
private:
NONVIRTUAL
VOID
Construct(
);
NONVIRTUAL
VOID
Destroy(
);
CACHE _cache;
};
#endif // _READ_CACHE_DEFN_