C# Класс SIPSorcery.Entities.TimeZoneHelper

Показать файл Открыть проект

Открытые методы

Метод Описание
ApplyOffset ( string dateTimeOffsetStr, int offset ) : System.DateTime

Applies a minutes offset to a date time offset.

GetTimeZonesUTCOffsetMinutes ( string timezoneStr ) : int

Returns the offset minutes from UTC time for a timezone. This method is typically used to convert times that are stored in the database as UTC time to a user's local time.

Описание методов

ApplyOffset() публичный статический Метод

Applies a minutes offset to a date time offset.
public static ApplyOffset ( string dateTimeOffsetStr, int offset ) : System.DateTime
dateTimeOffsetStr string Must be a valid DateTimeOffset. Typically this calue should be coming from the database.
offset int The offset in minutes to apply to the time string.
Результат System.DateTime

GetTimeZonesUTCOffsetMinutes() публичный статический Метод

Returns the offset minutes from UTC time for a timezone. This method is typically used to convert times that are stored in the database as UTC time to a user's local time.
public static GetTimeZonesUTCOffsetMinutes ( string timezoneStr ) : int
timezoneStr string The timezone to get the offset from UTC for.
Результат int