Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Interlocked::CompareExchange Method

 

Compares two values for equality and, if they are equal, replaces the first value.

Namespace:   System.Threading
Assembly:  mscorlib (in mscorlib.dll)

NameDescription
System_CAPS_pubmethodSystem_CAPS_staticCompareExchange(Double%, Double, Double)

Compares two double-precision floating point numbers for equality and, if they are equal, replaces the first value.

System_CAPS_pubmethodSystem_CAPS_staticCompareExchange(Int32%, Int32, Int32)

Compares two 32-bit signed integers for equality and, if they are equal, replaces the first value.

System_CAPS_pubmethodSystem_CAPS_staticCompareExchange(Int64%, Int64, Int64)

Compares two 64-bit signed integers for equality and, if they are equal, replaces the first value.

System_CAPS_pubmethodSystem_CAPS_staticCompareExchange(IntPtr%, IntPtr, IntPtr)

Compares two platform-specific handles or pointers for equality and, if they are equal, replaces the first one.

System_CAPS_pubmethodSystem_CAPS_staticCompareExchange(Object^%, Object^, Object^)

Compares two objects for reference equality and, if they are equal, replaces the first object.

System_CAPS_pubmethodSystem_CAPS_staticCompareExchange(Single%, Single, Single)

Compares two single-precision floating point numbers for equality and, if they are equal, replaces the first value.

System_CAPS_pubmethodSystem_CAPS_staticCompareExchange<T>(T%, T, T)

Compares two instances of the specified reference type T for equality and, if they are equal, replaces the first one.

Return to top
Show:
© 2017 Microsoft