Declaration¶
Source position: fpobserver.pp line 199
type
TBaseListMediator = class(TBaseMediator)
public
constructor Create;
destructor Destroy;
class function CompositeMediator : Boolean;
procedure ObservedChanged;
property SelectedObject: TObject; {rw}
published
property OnBeforeSetupField: TOnBeforeSetupField; {rw}
end;
Inheritance¶
Description¶
The TBaseListMediator class extends TBaseMediator to handle collections of objects. It creates individual item mediators for each object in the list and manages their lifecycle automatically.
The subject must be a TObjectList, TList, or TCollection. The mediator responds to list changes by creating, updating, or destroying item mediators as needed. T his class is abstract and must be subclassed to provide specific GUI integration.
Each item in the list is handled by a TListItemMediator instance, allowing individual objects to have their own observer relationships and data binding behavior.
Properties¶
| Member | Visibility | Description |
|---|---|---|
| SelectedObject | public | Currently selected object in the list |
Methods¶
| Member | Visibility | Description |
|---|---|---|
| CompositeMediator | public | Returns True indicating this is a composite mediator |
| Create | public | Creates a base list mediator instance |
| Destroy | public | Destroys the list mediator and all item mediators |
| ObservedChanged | public | Handles changes in the observed list objects |
Events¶
| Member | Visibility | Description |
|---|---|---|
| OnBeforeSetupField | published | Event for formatting field values in all item mediators |
See also¶
| Name | Description |
|---|---|
| TBaseMediator | Base class for mediating data between model and view objects |