|
Compare
Compares the two values, whether one of them is "greater than, less than or equal to" the other one.
A version for comparing two bool values.
int Compare(
|
A version for comparing two char values.
int Compare(
|
A version for comparing two uchar values.
int Compare(
|
A version for comparing two short values.
int Compare(
|
A version for comparing two ushort values.
int Compare(
|
A version for comparing two color values.
int Compare(
|
A version for comparing two int values.
int Compare(
|
A version for comparing two uint values.
int Compare(
|
A version for comparing two datetime values.
int Compare(
|
A version for comparing two long values.
int Compare(
|
A version for comparing two ulong values.
int Compare(
|
A version for comparing two float values.
int Compare(
|
A version for comparing two double values.
int Compare(
|
A version for comparing two string values.
int Compare(
|
A version for comparing two values of other types.
template<typename T>
|
Parameters
x
[in] The first value
y
[in] The second value
Return Value
Returns a number that expresses the ratio of the two compared values:
Note
If the T type is an object that implements the IComparable<T> interface, then the objects will be compared based on its Compare method. In all other cases, 0 is returned.