Class TimeZoneInfo
Provides basic information about a time zone.
Inheritance
Inherited Members
Namespace: Nevatech.Vsb.Repository.Entities
Assembly: Nevatech.Vsb.Repository.dll
Syntax
public sealed class TimeZoneInfo
Constructors
TimeZoneInfo()
Initializes an empty instance.
Declaration
public TimeZoneInfo()
Properties
Id
Gets or sets time zone identifier.
Declaration
public string Id { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Name
Gets or sets time zone display name.
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
System.String |
References
Gets or sets the optional number of references pointing to this time zone in a specific scope.
Declaration
public int? References { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Int32> |
UtcOffset
Gets or sets time difference (in minutes) between the current time in the time zone and UTC.
Declaration
public TimeSpan UtcOffset { get; set; }
Property Value
Type | Description |
---|---|
System.TimeSpan |
Methods
Create(String)
Created TimeZoneInfo instance and populates it from the System.TimeZoneInfo corresponding to the provided identifier.
Declaration
public static TimeZoneInfo Create(string timeZoneId)
Parameters
Type | Name | Description |
---|---|---|
System.String | timeZoneId | Identifier of the time zone. |
Returns
Type | Description |
---|---|
TimeZoneInfo | New instance of TimeZoneInfo instance and populates it from the System.TimeZoneInfo corresponding to the provided identifier. |
Create(TimeZoneInfo)
Creates TimeZoneInfo from provided System.TimeZoneInfo.
Declaration
public static TimeZoneInfo Create(TimeZoneInfo zone)
Parameters
Type | Name | Description |
---|---|---|
System.TimeZoneInfo | zone | System.TimeZoneInfo that will be used to populate new instance of the TimeZoneInfo. |
Returns
Type | Description |
---|---|
TimeZoneInfo | New instance of TimeZoneInfo populated from provided System.TimeZoneInfo. |
GetSystemTimeZones()
Returns collection of all time zones in the system.
Declaration
public static Collection<TimeZoneInfo> GetSystemTimeZones()
Returns
Type | Description |
---|---|
System.Collections.ObjectModel.Collection<TimeZoneInfo> | Collection of all time zones in the system. |