// Borland C++ Builder
// Copyright (c) 1995, 1998 by Borland International
// All rights reserved

// (DO NOT EDIT: machine generated header) 'AHMTDiskMonitor.pas' rev: 3.00

#ifndef AHMTDiskMonitorHPP
#define AHMTDiskMonitorHPP
#include <AHMSystemConst.hpp>
#include <AHMSystemClass.hpp>
#include <Classes.hpp>
#include <SysUtils.hpp>
#include <Messages.hpp>
#include <Windows.hpp>
#include <SysInit.hpp>
#include <System.hpp>

//-- user supplied -----------------------------------------------------------

namespace Ahmtdiskmonitor
{
//-- type declarations -------------------------------------------------------
enum TAHMMonitorType { monFiles, monDirectories, monAttributes, monSize, monLastWrite, monSecurity }
	;

typedef Set<TAHMMonitorType, monFiles, monSecurity>  TAHMMonitorSet;

class DELPHICLASS TAHMChangeThread;
class DELPHICLASS TAHMDiskLocation;
class DELPHICLASS TAHMDiskMonitor;
class DELPHICLASS TAHMDiskLocations;
class PASCALIMPLEMENTATION TAHMDiskLocations : public Classes::TCollection 
{
	typedef Classes::TCollection inherited;
	
private:
	TAHMDiskMonitor* FAHMDiskMonitor;
	TAHMDiskLocation* __fastcall GetAHMDiskLocation(int Index);
	void __fastcall SetAHMDiskLocation(int Index, TAHMDiskLocation* Value);
	
protected:
	DYNAMIC Classes::TPersistent* __fastcall GetOwner(void);
	
public:
	__fastcall TAHMDiskLocations(TAHMDiskMonitor* AOwner);
	HIDESBASE TAHMDiskLocation* __fastcall Add(void);
	bool __fastcall Delete(int Index);
	__property TAHMDiskMonitor* Owner = {read=FAHMDiskMonitor};
	__property TAHMDiskLocation* Items[int Index] = {read=GetAHMDiskLocation, write=SetAHMDiskLocation/*
		, default*/};
public:
	/* TCollection.Destroy */ __fastcall virtual ~TAHMDiskLocations(void) { }
	
};

class PASCALIMPLEMENTATION TAHMDiskMonitor : public Ahmsystemclass::TAHMSystemsComponent 
{
	typedef Ahmsystemclass::TAHMSystemsComponent inherited;
	
private:
	TAHMDiskLocations* FAHMDiskLocations;
	void __fastcall SetAHMDiskLocations(TAHMDiskLocations* Value);
	
public:
	__fastcall virtual TAHMDiskMonitor(Classes::TComponent* AOwner);
	__fastcall virtual ~TAHMDiskMonitor(void);
	
__published:
	__property TAHMDiskLocations* Locations = {read=FAHMDiskLocations, write=SetAHMDiskLocations};
};

class PASCALIMPLEMENTATION TAHMDiskLocation : public Classes::TCollectionItem 
{
	typedef Classes::TCollectionItem inherited;
	
private:
	bool FEnabled;
	int FMonType;
	TAHMChangeThread* FChangeThread;
	TThreadPriority FThreadPriority;
	TAHMDiskMonitor* FAHMDiskMonitor;
	Classes::TNotifyEvent FOnChangeOccured;
	System::AnsiString FLocation;
	TAHMMonitorSet FEvents;
	bool FSubDirectory;
	void __fastcall SetEnabled(const bool Value);
	void __fastcall SetThreadPriority(const Classes::TThreadPriority Value);
	void __fastcall SetLocation(const System::AnsiString Value);
	void __fastcall SetEvents(const TAHMMonitorSet Value);
	void __fastcall SetSubDirectory(const bool Value);
	
protected:
	virtual System::AnsiString __fastcall GetDisplayName(void);
	void __fastcall UpdateTimer(void);
	
public:
	__fastcall virtual TAHMDiskLocation(Classes::TCollection* Collection);
	virtual void __fastcall Assign(Classes::TPersistent* Source);
	__property TAHMDiskMonitor* Owner = {read=FAHMDiskMonitor};
	__property System::AnsiString DisplayName = {read=GetDisplayName};
	__fastcall virtual ~TAHMDiskLocation(void);
	
__published:
	__property Classes::TNotifyEvent OnChangeOccured = {read=FOnChangeOccured, write=FOnChangeOccured};
		
	__property System::AnsiString Location = {read=FLocation, write=SetLocation};
	__property bool Enabled = {read=FEnabled, write=SetEnabled, default=1};
	__property TAHMMonitorSet Events = {read=FEvents, write=SetEvents, default=0};
	__property bool SubDirectory = {read=FSubDirectory, write=SetSubDirectory, default=0};
	__property Classes::TThreadPriority Priority = {read=FThreadPriority, write=SetThreadPriority, default=3
		};
};

class PASCALIMPLEMENTATION TAHMChangeThread : public Classes::TThread 
{
	typedef Classes::TThread inherited;
	
public:
	TAHMDiskLocation* OwnerTimer;
	virtual void __fastcall Execute(void);
	void __fastcall DoTimer(void);
public:
	/* TThread.Create */ __fastcall TAHMChangeThread(bool CreateSuspended) : Classes::TThread(CreateSuspended
		) { }
	/* TThread.Destroy */ __fastcall virtual ~TAHMChangeThread(void) { }
	
};

//-- var, const, procedure ---------------------------------------------------

}	/* namespace Ahmtdiskmonitor */
#if !defined(NO_IMPLICIT_NAMESPACE_USE)
using namespace Ahmtdiskmonitor;
#endif
//-- end unit ----------------------------------------------------------------
#endif	// AHMTDiskMonitor
