Επεξεργασία

Κοινή χρήση μέσω


NFloat.CompareTo Method

Definition

Overloads

CompareTo(Object)

Compares this instance to a specified object and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified object.

CompareTo(NFloat)

Compares this instance to a specified floating-point number and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified floating-point number.

CompareTo(Object)

Source:
NFloat.cs
Source:
NFloat.cs
Source:
NFloat.cs

Compares this instance to a specified object and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified object.

public:
 virtual int CompareTo(System::Object ^ obj);
public int CompareTo (object? obj);
abstract member CompareTo : obj -> int
override this.CompareTo : obj -> int
Public Function CompareTo (obj As Object) As Integer

Parameters

obj
Object

An object to compare, or null.

Returns

A signed number indicating the relative values of this instance and obj.

Return ValueDescription
Less than zeroThis instance is less than obj, or this instance is not a number and obj is a number.
ZeroThis instance is equal to obj, or both this instance and obj are not a number.
Greater than zeroThis instance is greater than obj, or this instance is a number and obj is not a number or obj is null.

Implements

Exceptions

obj is not a NFloat.

Applies to

CompareTo(NFloat)

Source:
NFloat.cs
Source:
NFloat.cs
Source:
NFloat.cs

Compares this instance to a specified floating-point number and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified floating-point number.

public:
 virtual int CompareTo(System::Runtime::InteropServices::NFloat other);
public int CompareTo (System.Runtime.InteropServices.NFloat other);
abstract member CompareTo : System.Runtime.InteropServices.NFloat -> int
override this.CompareTo : System.Runtime.InteropServices.NFloat -> int
Public Function CompareTo (other As NFloat) As Integer

Parameters

other
NFloat

A floating-point number to compare.

Returns

A signed number indicating the relative values of this instance and other.

Return ValueDescription
Less than zeroThis instance is less than other, or this instance is not a number and other is a number.
ZeroThis instance is equal to other, or both this instance and other are not a number.
Greater than zeroThis instance is greater than other, or this instance is a number and other is not a number.

Implements

Applies to