[This is preliminary documentation and is subject to change.]
Base class for ZonedDateTime comparers.

C# | Visual Basic | Visual C++ |
public abstract class Comparer : IComparer<ZonedDateTime>
Public MustInherit Class Comparer _ Implements IComparer(Of ZonedDateTime)
public ref class Comparer abstract : IComparer<ZonedDateTime>

All Members | Methods | Properties | |||
Icon | Member | Description |
---|---|---|
![]() | Compare(ZonedDateTime, ZonedDateTime) | Compares two objects and returns a value indicating whether one is less than, equal to, or greater than the other. |
![]() ![]() | Instant |
Returns a comparer which compares ZonedDateTime values by the instants obtained by applying the offset to
the local date/time, ignoring the calendar system.
|
![]() ![]() | Local |
Returns a comparer which compares ZonedDateTime values by their local date/time, without reference to
the time zone, offset or the calendar system.
|

Use the static properties of this class to obtain instances.
For the curious: this class only exists so that in the future, it can expose more functionality - probably implementing IEqualityComparer<(Of <(<'T>)>)>. If we simply provided properties on ZonedDateTime of type IComparer<(Of <(<'T>)>)> we'd have no backward-compatible way of adding to the set of implemented interfaces.

Object | |
![]() | ZonedDateTime..::..Comparer |
Assembly: NodaTime (Module: NodaTime.dll) Version: 1.2.0.0 (1.2.0)