Noda Time
CompareTo Method (other)
NamespacesNodaTimeLocalDateCompareTo(LocalDate)

[This is preliminary documentation and is subject to change.]

Indicates whether this date is earlier, later or the same as another one.
Declaration Syntax
C#Visual BasicVisual C++
public int CompareTo(
	LocalDate other
)
Public Function CompareTo ( _
	other As LocalDate _
) As Integer
public:
virtual int CompareTo(
	LocalDate other
) sealed
Parameters
other (LocalDate)
The other date to compare this one with
Return Value
A value less than zero if this date is earlier than other; zero if this date is the same as other; a value greater than zero if this date is later than other.
Remarks
The comparison is performed in terms of a calendar-independent notion of date; the calendar systems of both LocalDate values are ignored. When both values use the same calendar, this is absolutely natural. However, when comparing a value in one calendar with a value in another, this can lead to surprising results. For example, 1945 in the ISO calendar corresponds to around 1364 in the Islamic calendar, so an Islamic date in year 1400 is "after" a date in 1945 in the ISO calendar.

Assembly: NodaTime (Module: NodaTime.dll) Version: 1.2.0.0 (1.2.0)