System.SyncObjs.TInterlocked.Add

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

class function Add(var Target: Integer; Increment: Integer): Integer; overload; static; inline;
class function Add(var Target: Int64; Increment: Int64): Int64; overload; static; inline;

C++

static int __fastcall Add(int &Target, int Increment)/* overload */;
static __int64 __fastcall Add(__int64 &Target, __int64 Increment)/* overload */;

Properties

Type Visibility Source Unit Parent
function public
System.SyncObjs.pas
System.SyncObjs.hpp
System.SyncObjs TInterlocked

Description

Increments an integer value with another.

There are two overloaded Add methods. Both Add methods increment a Target by Increment. The first method's parameters' type is Integer, while the second method's parameters' type is Int64.

The method returns the value of the incremented parameter in the corresponding type.

See Also