System.TGUID.operator Inequality

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

class operator NotEqual(const Left, Right: TGUID): Boolean; inline;

Properties

Type Visibility Source Unit Parent
function public System.pas System TGUID

Description

Overloaded <> operator.

operator Inequality returns True if the two TGUID values given as parameters are not equal, False otherwise.

Note: Do not call the Inequality operator directly. It is an overload for the <> operator.

 var a, b: TGUID;
 if (a <> b) then
   ; // Do something

There is also a C++ implementation of the != operator:

 void checkObject(IPersist* p)
 {
   TGUID clsid;
   p->GetClassID(&clsid);
   if (clsid != CLSID_MyObject)
     ;// Error!!
 }

Note: Do not call the Inequality operator directly. It is an overload of the compiler inequality operation.


See Also