Noda Time
DateTimeZoneCache Class
NamespacesNodaTime.TimeZonesDateTimeZoneCache

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

Provides an implementation of IDateTimeZoneProvider that caches results from an IDateTimeZoneSource.
Declaration Syntax
C#Visual BasicVisual C++
public sealed class DateTimeZoneCache : IDateTimeZoneProvider
Public NotInheritable Class DateTimeZoneCache _
	Implements IDateTimeZoneProvider
public ref class DateTimeZoneCache sealed : IDateTimeZoneProvider
Members
All MembersConstructorsMethodsProperties



IconMemberDescription
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.

Remarks
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.
Thread Safety
All members of this type are thread-safe as long as the underlying IDateTimeZoneSource implementation is thread-safe.
Inheritance Hierarchy
Object
DateTimeZoneCache
See Also

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