예제 #1
0
 private TimeZoneInfoEx(TZI source)
 {
     _source = source;
     Name = source.Name;
     StandardName = source.StandardName;
     DaylightName = source.DaylightName;
     BaseUtcOffset = source.BaseUtcOffset;
 }
예제 #2
0
 private TimeZoneInfoEx(TZI source)
 {
     _source       = source;
     Name          = source.Name;
     StandardName  = source.StandardName;
     DaylightName  = source.DaylightName;
     BaseUtcOffset = source.BaseUtcOffset;
 }
예제 #3
0
        public static TimeZoneInfoEx GetLocalTimeZone()
        {
            var name = TZI.GetLocalTimeStandardName();

            // get the id from the standard name
            var id = _timeZoneData.Value.Values.First(tzi => tzi.StandardName == name);

            return(FindSystemTimeZoneById(id.Name));
        }
예제 #4
0
 private static IDictionary <string, TimeZoneInfoEx> FillData()
 {
     return(TZI.CreateMap().Values.Select(tz => new TimeZoneInfoEx(tz)).ToDictionary(tz => tz.Name));
 }