[Overview][Classes][Procedures and functions][Index] Reference for unit 'LazMethodList' (#lazutils)

SameMethod

Determines whether the specified method instances contain the same code and data.

Declaration

Source position: lazmethodlist.pas line 67

function SameMethod(

  const m1: TMethod;

  const m2: TMethod

):Boolean;

Arguments

m1

  

First method instance examined in the routine.

m2

  

Second method instance examined in the routine.

Description

SameMethod is a Boolean function which returns True when m1 and m2 contain the same code and data in the TMethod instances. The comparison examines the Code and Data members in the TMethod records. The return value is True when the Code and Data members are identical in both records.

SameMethod replaces the deprecated CompareMethods routine in LCL version 2.3.

Used in the implementation of the IndexOf method in TMethodList, and when reading the value for the Current property in TItemsEnumerator.

See also

TMethodList.IndexOf

  

Gets the position where the specified method is stored in the list.

TMethod


Version 4.0 Generated 2025-05-03 Home