Table of Contents

Class ZonedClock

Namespace
LfrlAnvil.Chrono
Assembly
LfrlAnvil.Chrono.dll

Represents a provider of ZonedDateTime instances.

public sealed class ZonedClock : ZonedClockBase, IZonedClock, IGenerator<ZonedDateTime>, IGenerator
Inheritance
ZonedClock
Implements
Inherited Members
Extension Methods

Constructors

ZonedClock(TimeZoneInfo)

Creates a new ZonedClock instance.

public ZonedClock(TimeZoneInfo timeZone)

Parameters

timeZone TimeZoneInfo

Time zone of this clock.

Fields

Local

ZonedClock instance that returns ZonedDateTime instances in the Local time zone.

public static readonly ZonedClock Local

Field Value

ZonedClock

Utc

ZonedClock instance that returns ZonedDateTime instances in the Utc time zone.

public static readonly ZonedClock Utc

Field Value

ZonedClock

Methods

GetNow()

Returns the current ZonedDateTime.

[Pure]
public override ZonedDateTime GetNow()

Returns

ZonedDateTime

Current ZonedDateTime.