[Overview][Resource strings][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'daemonapp' (#fcl)

# TCustomDaemon

[Properties (by Name)] [Methods (by Name)] [Events (by Name)]

Base daemon application class

## Declaration

Source position: daemonapp.pp line 41

`type TCustomDaemon = class(TDataModule)`
`public`
`procedure CheckControlMessages();` |  |
`procedure LogMessage();` |  | Log a message to the system log
`procedure ReportStatus;` |  | Report the current status to the operating system
`property Definition: TDaemonDef; [r]` |  | The definition used to instantiate this daemon instance
`property DaemonThread: TThread; [r]` |  | Thread in which daemon is running
`property Controller: TDaemonController; [r]` |  | TDaemonController instance controlling this daemon instance
`property Status: TCurrentStatus; [rw]` |  | Current status of the daemon
`property Logger: TEventLog; [r]` |  | TEventLog instance used to send messages to the system log
`end;`

## Inheritance

`TCustomDaemon` |  | Base daemon application class
`TDataModule`
`TComponent,IUnknown,IInterfaceComponentReference`
`TPersistent,IFPObserved`
`TObject`

## Description

TCustomDaemon implements all the basic calls that are needed for a daemon to function. Descendents of TCustomDaemon can override these calls to implement the daemon-specific behaviour.

TCustomDaemon is an abstract class, it should never be instantiated. Either a descendent of it must be created and instantiated, or a descendent of TDaemon can be designed to implement the behaviour of the daemon.

## See also

TDaemon |  | Daemon class for visual development
TDaemonDef |  | Daemon definition
TDaemonController |  | Internal daemon controller class
TDaemonApplication |  | Default descendent of CustomDaemonApplication