Skip to main content

csFreeNotification

csFreeNotification = 8

Example

function HasFreeNotificationObservers(const State: TComponentState): Boolean;
begin
Result := csFreeNotification in State;
end;

Usage

csFreeNotification marks that one or more components requested notification when this component is destroyed; it does not convey ownership.

Additional Technical Info

csFreeNotification is member ordinal 8 of the component-state element enumeration and a flag in TComponentState. The framework sets it when other components have registered to receive destruction notification for this component.

The flag does not identify the observers, promise that callbacks are safe, keep the component alive or transfer/free ownership. It also does not mean this component observes someone else. Destruction notifications are framework bookkeeping, not an application event subscription contract.

The property is read-only and can change as components register/remove notifications. Do not use it as a concurrency or lifetime guard. The example is source-reviewed only; no notification was registered.

External references

Created 2026-07-15