Class RealTimeProvider
- Namespace
- FinanceSharp
- Assembly
- FinanceSharp.dll
Provides an implementation of ITimeProvider that uses UtcNow to provide the current time
public sealed class RealTimeProvider : ITimeProvider
- Inheritance
-
RealTimeProvider
- Implements
- Inherited Members
- Extension Methods
Fields
Instance
Provides a static instance of the RealTimeProvider
public static readonly ITimeProvider Instance
Field Value
Remarks
Since this implementation is stateless, it doesn't make sense to have multiple instances.
Methods
GetUtcNow()
Gets the current time in UTC
public DateTime GetUtcNow()
Returns
- DateTime
The current time in UTC