PIIdentityMapping.CompareTo Method (PIIdentityMapping)
- Last UpdatedNov 18, 2025
- 2 minute read
- PI System
- AF SDK 2024 R2
- Developer
Compares this instance with a specified PIIdentityMapping.
Namespace: OSIsoft.AF.PI
Assembly: OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182
Syntax
public int CompareTo( PIIdentityMapping obj )
Public Function CompareTo ( obj As PIIdentityMapping ) As Integer Dim instance As PIIdentityMapping Dim obj As PIIdentityMapping Dim returnValue As Integer returnValue = instance.CompareTo(obj)
public: virtual int CompareTo( PIIdentityMapping^ obj ) sealed
abstract CompareTo : obj : PIIdentityMapping -> int override CompareTo : obj : PIIdentityMapping -> int
Parameters
- obj
- Type: OSIsoft.AF.PIPIIdentityMapping
The object to be compared.
Return Value
Type: Int32A 32-bit signed integer that indicates the relative order of the comparands. The return value has these meanings:
| Value | Meaning |
|---|---|
| Less than zero | This instance is less than obj. |
| Zero | This instance is equal to obj. |
| Greater than zero | This instance is greater than obj. |
Implements
IComparableTCompareTo(T)
Exceptions
| Exception | Condition |
|---|---|
| ArgumentException | The obj parameter is not the same type as this instance. |
Remarks
By definition, any object compares greater than and two null references compare equal to each other.
This method uses the Name of the objects to perform the comparison operation.
Version Information
AFSDK
Supported in: 3.1.1, 3.1.0, 3.0.2, 3.0.1, 3.0.0, 2.10.11, 2.10.5, 2.10.0, 2.10, 2.9.5, 2.9, 2.8.5, 2.8, 2.7.5, 2.7, 2.6
See Also
Reference
List<T>.Sort()