TReferenceList.Add Method

Overload List

#SignatureDescription
1void Add(TMtxComponent Src)Add a reference of Src to Self and also a reference of Self to Src.
2void Add(TReferenceList Src, TNotifyEvent Event, Object CompSrc)Add a reference to Src to Self and also a reference of Self to Src.

Overload 1: void Add(TMtxComponent Src)

Add a reference of Src to Self and also a reference of Self to Src.

#NameTypeDescription
1SrcTMtxComponent

Result: stored in self (calling object)

Remarks:

Event that will be called, when the connected component is destroyed is the method TMtxComponent.RemoveReference. The parameter passed to the method will be the pointer of the component (and not of its TReferenceList) that is being destroyed.

Overload 2: void Add(TReferenceList Src, TNotifyEvent Event, Object CompSrc)

Add a reference to Src to Self and also a reference of Self to Src.

#NameTypeDescription
1SrcTReferenceList
2EventTNotifyEvent
3CompSrcObject

Result: stored in self (calling object)

Remarks:

Event is the procedure to be called, when the connected component is destroyed.