[This is preliminary documentation and is subject to change.]
Provides an implementation of IDateTimeZoneProvider that caches results from an
IDateTimeZoneSource.
| C# | Visual Basic | Visual C++ |
public sealed class DateTimeZoneCache : IDateTimeZoneProvider
Public NotInheritable Class DateTimeZoneCache _ Implements IDateTimeZoneProvider
public ref class DateTimeZoneCache sealed : IDateTimeZoneProvider
| All Members | Constructors | Methods | Properties | ||
| Icon | Member | Description |
|---|---|---|
| DateTimeZoneCache(IDateTimeZoneSource) |
Creates a provider backed by the given IDateTimeZoneSource.
| |
| GetSystemDefault()()()() |
Gets the time zone from this provider that matches the system default time zone, if a matching time zone is
available.
| |
| GetZoneOrNull(String) |
Returns the time zone for the given ID, if it's available.
| |
| Ids |
Gets the list of valid time zone ids advertised by this provider.
| |
| Item[([( String])]) |
Returns the time zone for the given ID.
| |
| VersionId |
The version ID of this provider. This is simply the VersionId returned by
the underlying source.
|
The process of loading or creating time zones may be an expensive operation. This class implements an
unlimited-size non-expiring cache over a time zone source, and adapts an implementation of the
IDateTimeZoneSource interface to an IDateTimeZoneProvider.
All members of this type are thread-safe as long as the underlying IDateTimeZoneSource
implementation is thread-safe.
| Object | |
| DateTimeZoneCache | |
Assembly: NodaTime (Module: NodaTime.dll) Version: 1.2.0.0 (1.2.0)