334 instantiations of DateTime
mscorlib (139)
system\convert.cs (2)
1726return new DateTime(0); 1732return new DateTime(0);
system\currenttimezone.cs (6)
150return new DateTime(DateTime.MaxTicks, DateTimeKind.Local); 153return new DateTime(DateTime.MinTicks, DateTimeKind.Local); 155return new DateTime(tick, DateTimeKind.Local, isAmbiguousLocalDst); 259time = new DateTime(year, month, (day < numberOfSunday) ? day : numberOfSunday, 267time = new DateTime(year, month, 1, hour, minute, second, millisecond, DateTimeKind.Local); 284time = new DateTime(year, month, cal.GetDaysInMonth(year, month), hour, minute, second, millisecond, DateTimeKind.Local);
system\datetime.cs (28)
116public static readonly DateTime MinValue = new DateTime(MinTicks, DateTimeKind.Unspecified); 117public static readonly DateTime MaxValue = new DateTime(MaxTicks, DateTimeKind.Unspecified); 245DateTime dt = new DateTime(dateData); 329DateTime dt = new DateTime(dateData); 364DateTime dt = new DateTime(dateData); 523return new DateTime((UInt64)(DateToTicks(y, m, d) + InternalTicks % TicksPerDay) | InternalKind); 545return new DateTime((UInt64)(ticks + value) | InternalKind); 724DateTime utcDt = new DateTime(ticks, DateTimeKind.Utc); 737return new DateTime(ticks, DateTimeKind.Local, isAmbiguousLocalDst); 750return new DateTime((UInt64)dateData); 774return new DateTime(universalTicks, DateTimeKind.Utc); 780return new DateTime(DoubleDateToTicks(d), DateTimeKind.Unspecified); 805return new DateTime(value.InternalTicks, kind); 846return new DateTime((UInt64)(ticks - ticks % TicksPerDay) | InternalKind); 1060return new DateTime(DateTime.MaxTicks, DateTimeKind.Local); 1063return new DateTime(DateTime.MinTicks, DateTimeKind.Local); 1065return new DateTime(tick, DateTimeKind.Local, isAmbiguousLocalDst); 1093return new DateTime( ((UInt64)(ticks + FileTimeOffset)) | KindUtc); 1117DateTime dt = new DateTime(ticks); 1210return new DateTime( ((UInt64)(ticks)) | KindUtc); 1216DateTime dt = new DateTime(year, month, day); 1342return new DateTime((UInt64)(ticks - valueTicks) | InternalKind); 1410return new DateTime(DateTime.MaxTicks, DateTimeKind.Local); 1417return new DateTime(DateTime.MinTicks, DateTimeKind.Local); 1419return new DateTime(tick, DateTimeKind.Local, isAmbiguousLocalDst); 1491return new DateTime((UInt64)(ticks + valueTicks) | d.InternalKind); 1500return new DateTime((UInt64)(ticks - valueTicks) | d.InternalKind); 1696result = new DateTime(ticks, DateTimeKind.Unspecified);
system\datetimeoffset.cs (6)
63DateTime dateTime = new DateTime(ticks); 111m_dateTime = ValidateDate(new DateTime(year, month, day, hour, minute, second), offset); 132m_dateTime = ValidateDate(new DateTime(year, month, day, hour, minute, second, millisecond), offset); 154m_dateTime = ValidateDate(new DateTime(year, month, day, hour, minute, second, millisecond, calendar), offset); 217return new DateTime((m_dateTime + Offset).Ticks, DateTimeKind.Unspecified); 807return new DateTime(utcTicks, DateTimeKind.Unspecified);
system\globalization\calendar.cs (1)
272return (new DateTime(ticks));
system\globalization\CalendricalCalculationsHelper.cs (5)
27static long StartOf1810 = GetNumberOfDays(new DateTime(1810, 1, 1)); 28static long StartOf1900Century = GetNumberOfDays(new DateTime(1900, 1, 1)); 77return new DateTime(Math.Min((long)(Math.Floor(numberOfDays) * GregorianCalendar.TicksPerDay), DateTime.MaxValue.Ticks)).Year; 150long july1stOfYear = GetNumberOfDays(new DateTime(gregorianYear, 7, 1)); 158long january1stOfYear = GetNumberOfDays(new DateTime(gregorianYear, 1, 1));
system\globalization\chineselunisolarcalendar.cs (3)
45internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 46internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999);
system\globalization\datetimeparse.cs (5)
2673result.parsedDate = new DateTime(utcTicks, DateTimeKind.Utc); 2698result.parsedDate = new DateTime(resultTicks, DateTimeKind.Utc); 2736DateTime utcDt = new DateTime(resultTicks, DateTimeKind.Utc); 2746result.parsedDate = new DateTime(resultTicks, DateTimeKind.Local, isAmbiguousLocalDst); 3348return new DateTime(DateTime.UtcNow.Ticks + result.timeZoneOffset.Ticks, DateTimeKind.Unspecified);
system\globalization\eastasianlunisolarcalendar.cs (2)
247return new DateTime(gy, gm, gd, hour, minute, second, millisecond); 614twoDigitYearMax = GetSystemTwoDigitYearSetting(BaseCalendarID, GetYear(new DateTime(DEFAULT_GREGORIAN_TWO_DIGIT_YEAR_MAX, 1, 1)));
system\globalization\gregoriancalendar.cs (2)
322return (new DateTime(ticks)); 570return new DateTime(year, month, day, hour, minute, second, millisecond);
system\globalization\gregoriancalendarhelper.cs (4)
41this.ticks = new DateTime(startYear, startMonth, startDay).Ticks; 51this.ticks = new DateTime(startYear, startMonth, startDay).Ticks; 420return (new DateTime(ticks)); 630return (new DateTime(ticks));
system\globalization\hebrewcalendar.cs (10)
296internal static readonly DateTime calendarMinValue = new DateTime(1583, 1, 1); 299internal static readonly DateTime calendarMaxValue = new DateTime((new DateTime(2239, 9, 29, 23, 59, 59, 999)).Ticks + 9999); 544DateTime time = new DateTime(ticks); 700return (new DateTime(ToDateTime(y, i, d, 0, 0, 0, 0).Ticks + (time.Ticks % TicksPerDay))); 743return (new DateTime(ticks)); 794beginOfYearDate = new DateTime(1582, 9, 27); 1003return (new DateTime(gregorianYear, 1, 1, hour, minute, second, millisecond)); 1008DateTime gregorianNewYear = new DateTime(gregorianYear, 1, 1); 1009return (new DateTime(gregorianNewYear.Ticks + days * TicksPerDay
system\globalization\hijricalendar.cs (3)
86internal static readonly DateTime calendarMinValue = new DateTime(622, 7, 18); 529return (new DateTime(ticks)); 699return (new DateTime(lDate * GregorianCalendar.TicksPerDay + TimeToTicks(hour, minute, second, millisecond)));
system\globalization\japanesecalendar.cs (1)
48internal static readonly DateTime calendarMinValue = new DateTime(1868, 9, 8);
system\globalization\japaneselunisolarcalendar.cs (3)
45internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 46internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999);
system\globalization\juliancalendar.cs (2)
262return (new DateTime(ticks)); 391return new DateTime(DateToTicks(year, month, day) + (new TimeSpan(0, hour, minute, second, millisecond)).Ticks);
system\globalization\koreanlunisolarcalendar.cs (3)
46internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 47internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999);
system\globalization\Persiancalendar.cs (4)
33internal static long PersianEpoch = new DateTime(622, 3, 22).Ticks / GregorianCalendar.TicksPerDay; 50internal static DateTime minDate = new DateTime(622, 3, 22); 320return (new DateTime(ticks)); 521return (new DateTime(lDate * GregorianCalendar.TicksPerDay + TimeToTicks(hour, minute, second, millisecond)));
system\globalization\taiwancalendar.cs (1)
63internal static readonly DateTime calendarMinValue = new DateTime(1912, 1, 1);
system\globalization\taiwanlunisolarcalendar.cs (3)
51internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 52internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999);
system\globalization\umalquracalendar.cs (6)
35GregorianDate = new DateTime(GYear, GMonth, GDay); 258internal static DateTime minDate = new DateTime(1900, 4, 30); 259internal static DateTime maxDate = new DateTime((new DateTime(2077, 11, 16, 23, 59, 59, 999)).Ticks + 9999); 560DateTime dt = new DateTime(GetAbsoluteDateUmAlQura(y, m, d) * TicksPerDay + time.Ticks % TicksPerDay); 787return (new DateTime(lDate * GregorianCalendar.TicksPerDay + TimeToTicks(hour, minute, second, millisecond)));
system\reflection\mdconstant.cs (1)
105return new DateTime(defaultValue);
system\reflection\parameterinfo.cs (1)
626return new DateTime((long)value.Value);
system\resources\resourcereader.cs (1)
640return new DateTime(_store.ReadInt64());
system\runtime\compilerservices\datetimeconstantattribute.cs (3)
18date = new System.DateTime(ticks); 38return new DateTime((long)namedArgument.TypedValue.Value); 43return new DateTime((long)attr.ConstructorArguments[0].Value);
system\runtime\remoting\soapinteroptypes.cs (1)
450set {_value = new DateTime(1, 1, 1, value.Hour, value.Minute, value.Second, value.Millisecond);}
system\timezone.cs (4)
101return new DateTime(DateTime.MaxTicks, DateTimeKind.Utc); 104return new DateTime(DateTime.MinTicks, DateTimeKind.Utc); 106return new DateTime(tickCount, DateTimeKind.Utc); 118return new DateTime(time.Ticks + offset, DateTimeKind.Local, isAmbiguousLocalDst);
system\timezoneinfo.cs (27)
274private static DateTime s_maxDateOnly = new DateTime(9999, 12, 31); 275private static DateTime s_minDateOnly = new DateTime(1, 1, 2); 816return new DateTime(targetConverted.Ticks, DateTimeKind.Local, isAmbiguousLocalDst); 819return new DateTime(targetConverted.Ticks, targetKind); 1339utcConverted = new DateTime(ticks); 1353localConverted = new DateTime(ticks); 1489startTime = rule.IsStartDateMarkerForBeginningOfYear() ? new DateTime(daylightTime.Start.Year, 1, 1, 0, 0, 0) : daylightTime.Start + daylightTime.Delta; 1490endTime = rule.IsEndDateMarkerForEndOfYear() ? new DateTime(daylightTime.End.Year + 1, 1, 1, 0, 0, 0).AddTicks(-1) : daylightTime.End; 1511startTime = rule.IsStartDateMarkerForBeginningOfYear() ? new DateTime(daylightTime.Start.Year, 1, 1, 0, 0, 0) : daylightTime.Start + (invalidAtStart ? rule.DaylightDelta : TimeSpan.Zero); /* FUTURE: - rule.StandardDelta; */ 1512endTime = rule.IsEndDateMarkerForEndOfYear() ? new DateTime(daylightTime.End.Year + 1, 1, 1, 0, 0, 0).AddTicks(-1) : daylightTime.End + (invalidAtStart ? -rule.DaylightDelta : TimeSpan.Zero); 1563AdjustmentRule previousYearRule = zone.GetAdjustmentRuleForTime(new DateTime(daylightTime.Start.Year - 1, 12, 31)); 1569startTime = new DateTime(daylightTime.Start.Year, 1, 1, 0, 0, 0) - offset; 1577AdjustmentRule nextYearRule = zone.GetAdjustmentRuleForTime(new DateTime(daylightTime.End.Year + 1, 1, 1)); 1580endTime = new DateTime(daylightTime.End.Year + 1, 12, 31) - utc - nextYearRule.BaseUtcOffsetDelta - nextYearRule.DaylightDelta; 1587endTime = new DateTime(daylightTime.End.Year + 1, 1, 1, 0, 0, 0).AddTicks(-1) - offset - rule.DaylightDelta; ; 2146new DateTime(1, /* year */ 2159new DateTime(1, /* year */ 2176new DateTime(1, /* year */ 2189new DateTime(1, /* year */ 2219value = new DateTime(year, transitionTime.Month, (day < transitionTime.Day) ? day : transitionTime.Day, 2227value = new DateTime(year, transitionTime.Month, 1, 2246value = new DateTime(year, transitionTime.Month, daysInMonth, 2381new DateTime(first, 12, 31), // December 31, <FirstYear> 2397new DateTime(i, 1, 1), // January 01, <Year> 2398new DateTime(i, 12, 31), // December 31, <Year> 2413new DateTime(last, 1, 1), // January 01, <LastYear> 4080timeOfDay = new DateTime(1, 1, 1, timeOfDay.Hour,timeOfDay.Minute,timeOfDay.Second, timeOfDay.Millisecond);
system\variant.cs (1)
405return new DateTime(GetI8FromVar());
PresentationBuildTasks (3)
BuildTasks\MS\Internal\Tasks\IncrementalCompileAnalyzer.cs (2)
324DateTime nonSet = new DateTime(0); 610private DateTime _lastCompileTime = new DateTime(0);
BuildTasks\MS\Internal\Tasks\TaskFileService.cs (1)
220DateTime lastChangeDT = new DateTime(0);
PresentationCore (2)
Core\CSharp\System\Windows\LayoutManager.cs (2)
284DateTime loopStartTime = new DateTime(0); 352loopStartTime = new DateTime(0);
PresentationFramework (13)
src\Framework\System\Windows\Controls\Calendar.cs (7)
734return new DateTime(DisplayDate.Year, 1, 1); 1386DateTime? selectedDate = new DateTime(this.DisplayDateInternal.Year, this.DisplayDateInternal.Month, 1); 1407DateTime selectedMonth = new DateTime(this.DisplayDate.Year, 12, 1); 1414DateTime? selectedYear = new DateTime(DateTimeHelper.EndOfDecade(this.DisplayDate), 1, 1); 1450DateTime? selectedDate = new DateTime(this.DisplayDateInternal.Year, this.DisplayDateInternal.Month, 1); 1457DateTime selectedMonth = new DateTime(this.DisplayDate.Year, 1, 1); 1464DateTime? selectedYear = new DateTime(DateTimeHelper.DecadeOfDate(this.DisplayDate), 1, 1);
src\Framework\System\Windows\Controls\DatePicker.cs (2)
1014DateTime newD = new DateTime(year, month, 1, 0, 0, 0); 1030DateTime newD = new DateTime(year, month, day, 0, 0, 0);
src\Framework\System\Windows\Controls\DateTimeHelper.cs (1)
87return new DateTime(d.Year, d.Month, 1, 0, 0, 0);
src\Framework\System\Windows\Controls\Primitives\CalendarItem.cs (2)
1257DateTime day = new DateTime(year, 1, 1); 1301DateTime day = new DateTime(DisplayDate.Year, count + 1, 1);
src\Framework\System\Windows\Markup\Baml2006\WpfGeneratedKnownTypes.cs (1)
3195bamlType.DefaultConstructor = delegate() { return new System.DateTime(); };
System (4)
net\System\Net\_FtpControlStream.cs (1)
921dateTime = new DateTime(year, month, day, hour, minute, second, millisecond);
net\System\Net\_HTTPDateParse.cs (2)
264dtOut = new DateTime(); 425dtOut = new DateTime (year, month, day, hour, minute, second, millisecond);
services\monitoring\system\diagnosticts\EventLogEntry.cs (1)
610private static readonly DateTime beginningOfTime = new DateTime(1970, 1, 1, 0, 0, 0);
System.Activities (1)
System\Activities\Expressions\Literal.cs (1)
117DateTime noLeftOverTicksDateTime = new DateTime(
System.Core (2)
System\Diagnostics\Eventing\Reader\NativeWrapper.cs (2)
1202return new DateTime(sysTime.Year, sysTime.Month, sysTime.Day, sysTime.Hour, sysTime.Minute, sysTime.Second, sysTime.Milliseconds); 1367array[i] = new DateTime(sysTime.Year, sysTime.Month, sysTime.Day, sysTime.Hour, sysTime.Minute, sysTime.Second, sysTime.Milliseconds);
System.Data (14)
fx\src\data\Microsoft\SqlServer\Server\SmiMetaData.cs (2)
78internal static readonly DateTime MaxSmallDateTime = new DateTime(2079, 06, 06, 23, 59, 29, 998); 79internal static readonly DateTime MinSmallDateTime = new DateTime(1899, 12, 31, 23, 59, 29, 999);
fx\src\data\Microsoft\SqlServer\Server\ValueUtilsSmi.cs (2)
2418private static readonly DateTime x_dtSmallMax = new DateTime(2079, 06, 06, 23, 59, 29, 998); 2419private static readonly DateTime x_dtSmallMin = new DateTime(1899, 12, 31, 23, 59, 29, 999);
fx\src\data\System\Data\ProviderBase\DbBuffer.cs (2)
589return new DateTime( 624DateTime value = new DateTime(
fx\src\data\System\Data\Sql\SqlMetaData.cs (3)
785return new DateTime(InternalAdjustTimeTicks(value.Ticks)); 1446private static readonly DateTime x_dtSmallMax = new DateTime(2079, 06, 06, 23, 59, 29, 998); 1447private static readonly DateTime x_dtSmallMin = new DateTime(1899, 12, 31, 23, 59, 29, 999);
fx\src\data\System\Data\SqlClient\SqlBuffer.cs (2)
185return new DateTime(GetTicksFromDateTime2Info(_value._dateTime2Info)); 367return new DateTime(_value._timeInfo.ticks).ToString(__katmaiTimeFormatByScale[scale], DateTimeFormatInfo.InvariantInfo);
fx\src\data\System\Data\SQLTypes\SQLDateTime.cs (3)
67private static readonly DateTime SQLBaseDate = new DateTime(1900, 1, 1); 86private static readonly DateTime MinDateTime = new DateTime(1753, 1, 1); 236DateTime result = new DateTime(SQLBaseDateTicks + dayticks + timeticks);
System.Data.Entity (2)
System\Data\Common\EntitySql\AST\Literal.cs (2)
521DateTime dateTime = new DateTime(year, month, day, hour, minute, second, 0); 561DateTime dateTime = new DateTime(year, month, day, hour, minute, second, 0);
System.Data.Linq (1)
DbConvert.cs (1)
132DateTime dt = new DateTime();
System.Data.Services (3)
System\Data\Services\Serializers\JsonReader.cs (1)
93DateTime dateTime = new DateTime(ticks * 10000 + JsonWriter.DatetimeMinTimeTicks, DateTimeKind.Utc);
System\Data\Services\Serializers\JsonWriter.cs (2)
28internal static readonly long DatetimeMinTimeTicks = (new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc)).Ticks; 272dateTime = new DateTime(dateTime.Ticks, DateTimeKind.Utc);
System.Data.Services.Client (1)
System\Data\Services\Client\ClientConvert.cs (1)
317return XmlConvert.ToString(dt.Kind == DateTimeKind.Unspecified && atomDateConstruct ? new DateTime(dt.Ticks, DateTimeKind.Utc) : dt, XmlDateTimeSerializationMode.RoundtripKind);
System.IdentityModel (10)
System\IdentityModel\DateTimeUtil.cs (2)
54return new DateTime(DateTime.MaxValue.Ticks, kind); 59return new DateTime(DateTime.MinValue.Ticks, kind);
System\IdentityModel\SecurityUtils.cs (2)
56return new DateTime(DateTime.MaxValue.Ticks - TimeSpan.TicksPerDay, DateTimeKind.Utc); 65return new DateTime(DateTime.MinValue.Ticks + TimeSpan.TicksPerDay, DateTimeKind.Utc);
System\IdentityModel\Tokens\SamlSecurityTokenHandler.cs (2)
48static DateTime WCFMinValue = new DateTime(DateTime.MinValue.Ticks + TimeSpan.TicksPerDay, DateTimeKind.Utc); 49static DateTime WCFMaxValue = new DateTime(DateTime.MaxValue.Ticks - TimeSpan.TicksPerDay, DateTimeKind.Utc);
System\IdentityModel\Tokens\SessionSecurityToken.cs (4)
465DateTime effectiveTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 471DateTime expiryTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 477DateTime keyEffectiveTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 483DateTime keyExpiryTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc);
System.Management (2)
ManagementDatetime.cs (2)
194 datetime = new System.DateTime(year, month, day, hour, minute, second, millisec); 294 DateTime dtTemp = new DateTime(date.Year ,date.Month,date.Day ,date.Hour ,date.Minute ,date.Second,0);
System.Messaging (7)
System\Messaging\ActiveXMessageFormatter.cs (1)
177return new DateTime(BitConverter.ToInt64(newBytes, 0));
System\Messaging\Message.cs (2)
431DateTime time = new DateTime(1970, 1, 1); 1621DateTime time = new DateTime(1970, 1, 1);
System\Messaging\MessageQueue.cs (2)
479DateTime time = new DateTime(1970, 1, 1); 792DateTime time = new DateTime(1970, 1, 1);
System\Messaging\MessageQueueCriteria.cs (2)
38private static DateTime minDate = new DateTime(1970, 1, 1); 39private static DateTime maxDate = new DateTime(2038, 1, 19);
System.Runtime.Caching (1)
System\Caching\MemoryCacheEntryChangeMonitor.cs (1)
15private static readonly DateTime DATETIME_MINVALUE_UTC = new DateTime(0, DateTimeKind.Utc);
System.Runtime.Serialization (3)
System\Runtime\Serialization\Json\JsonGlobals.cs (1)
36public static readonly long unixEpochTicks = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc).Ticks;
System\Runtime\Serialization\Json\JsonReaderDelegator.cs (1)
234DateTime dateTime = new DateTime(ticks, DateTimeKind.Utc);
System\Xml\XmlConverter.cs (1)
817value = new DateTime(year, month, day, hour, minute, second, kind);
System.ServiceModel (9)
System\ServiceModel\Channels\NativeMsmqMessage.cs (1)
585return new DateTime(1970, 1, 1).AddSeconds(seconds);
System\ServiceModel\Dispatcher\XPathMessageContext.cs (1)
204internal readonly static DateTime ZeroDate = new DateTime(1, 1, 1, 0, 0, 0, DateTimeKind.Utc);
System\ServiceModel\MsmqIntegration\ActiveXSerializer.cs (1)
142return new DateTime(BitConverter.ToInt64(bytes, 0));
System\ServiceModel\Security\SecurityUtils.cs (2)
374return new DateTime(DateTime.MaxValue.Ticks - TimeSpan.TicksPerDay, DateTimeKind.Utc); 383return new DateTime(DateTime.MinValue.Ticks + TimeSpan.TicksPerDay, DateTimeKind.Utc);
System\ServiceModel\Security\Tokens\SecurityContextCookieSerializer.cs (4)
70effectiveTime = new DateTime(XmlHelper.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 74expiryTime = new DateTime(XmlHelper.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 86keyEffectiveTime = new DateTime(XmlHelper.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 90keyExpirationTime = new DateTime(XmlHelper.ReadElementContentAsInt64(reader), DateTimeKind.Utc);
System.ServiceModel.Discovery (1)
System\ServiceModel\Discovery\DiscoveryMessageSequenceGenerator.cs (1)
12static readonly DateTime DT1970 = new DateTime(1970, 1, 1);
System.ServiceModel.Web (3)
System\ServiceModel\Description\WebScriptClientGenerator.cs (1)
38this.serviceLastModified = new DateTime(this.serviceLastModified.Year, this.serviceLastModified.Month, this.serviceLastModified.Day, this.serviceLastModified.Hour, this.serviceLastModified.Minute, this.serviceLastModified.Second, DateTimeKind.Utc);
System\ServiceModel\Web\HttpDateParse.cs (2)
256dtOut = new DateTime(); 431dtOut = new DateTime(year, month, day, hour, minute, second, millisecond);
System.Transactions (1)
System\Transactions\TransactionInformation.cs (1)
89return new DateTime( this.internalTransaction.CreationTime );
System.Web (24)
Handlers\AssemblyResourceLoader.cs (1)
643cachePolicy.SetLastModified(new DateTime((long)assemblyInfo.Second));
HttpCachePolicy.cs (1)
1693utcDate = new DateTime(utcDate.Ticks - (utcDate.Ticks % TimeSpan.TicksPerSecond));
Management\SqlWebEventProvider.cs (1)
259WriteToSQL(new WebBaseEventCollection(eventRaised), 0, new DateTime(0));
Security\ADMembershipProvider.cs (1)
116private readonly DateTime DefaultLastLockoutDate = new DateTime(1754, 1, 1, 0, 0, 0, DateTimeKind.Utc);
Security\AnonymousIdentificationModule.cs (2)
96cookie.Expires = new System.DateTime(1999, 10, 12); 176cookie.Expires = new System.DateTime(1999, 10, 12);
Security\FormsAuthentication.cs (1)
416cookie.Expires = new System.DateTime(1999, 10, 12);
Security\FormsAuthenticationTicketSerializer.cs (2)
69DateTime ticketIssueDateUtc = new DateTime(ticketIssueDateUtcTicks, DateTimeKind.Utc); 82DateTime ticketExpirationDateUtc = new DateTime(ticketExpirationDateUtcTicks, DateTimeKind.Utc);
Security\PassportIdentity.cs (1)
1010cookie.Expires = new DateTime(1998, 1, 1);
Security\Roles.cs (1)
439cookie.Expires = new System.DateTime(1999, 10, 12);
Security\SQLMembershipProvider.cs (2)
414new DateTime( 1754, 1, 1 ) ); 1895return new DateTime(utcDateTime.Year, utcDateTime.Month, utcDateTime.Day, utcDateTime.Hour, utcDateTime.Minute, utcDateTime.Second, DateTimeKind.Utc);
State\OutOfProcStateClientManager.cs (1)
493lockAge = now - new DateTime(results.lockDate);
StaticFileHandler.cs (2)
512lastModifiedInUtc = new DateTime(fileInfo.LastWriteTimeUtc.Year, 528lastModifiedInUtc = new DateTime(utcNow.Ticks - (utcNow.Ticks % TimeSpan.TicksPerSecond), DateTimeKind.Utc);
UI\WebControls\basecomparevalidator.cs (1)
376return new DateTime(year, month, day);
UI\WebControls\Calendar.cs (1)
69private static DateTime baseDate = new DateTime(2000, 1, 1);
Util\altserialization.cs (1)
184value = new DateTime(reader.ReadInt64());
Util\DateTimeUtil.cs (1)
31return new DateTime(universalTicks, DateTimeKind.Utc);
Util\FileUtil.cs (3)
596UtcCreationTime = new DateTime(0, DateTimeKind.Utc); 597UtcLastAccessTime = new DateTime(0, DateTimeKind.Utc); 598UtcLastWriteTime = new DateTime(0, DateTimeKind.Utc);
Util\ParseHttpDate.cs (1)
219return new DateTime(year, month, day, hour, minute, second, DateTimeKind.Utc);
System.Web.DataVisualization (21)
Common\DataManager\DataPoint.cs (4)
2128 DateTime time = new DateTime( 2140 DateTime time = new DateTime( 2296 DateTime date = new DateTime( 2317 DateTime time = new DateTime(
Common\General\ChartElement.cs (16)
987 DateTime sizeAdjustedDate = new DateTime(newStartDate.Year, 1, 1, 0, 0, 0); 1008 newStartDate = new DateTime(year, 1018 newStartDate = new DateTime(newStartDate.Year, 1028 newStartDate = new DateTime(newStartDate.Year, 1034 newStartDate = new DateTime(newStartDate.Year, 1040 newStartDate = new DateTime(newStartDate.Year, 1050 newStartDate = new DateTime(newStartDate.Year, 1061 newStartDate = new DateTime(newStartDate.Year, 1077 newStartDate = new DateTime(newStartDate.Year, 1202 roundedDateValue = new DateTime(dateValue.Year, 1207 roundedDateValue = new DateTime(dateValue.Year, 1212 roundedDateValue = new DateTime(dateValue.Year, 1217 roundedDateValue = new DateTime(dateValue.Year, 1223 roundedDateValue = new DateTime(dateValue.Year, 1232 roundedDateValue = new DateTime(dateValue.Year, 1242 roundedDateValue = new DateTime(dateValue.Year,
Common\Utilities\XmlSerializer.cs (1)
3130 objValue = new DateTime(reader.ReadInt64());
System.Web.Extensions (3)
Script\Serialization\JavaScriptObjectDeserializer.cs (1)
380DateTime dt = new DateTime(ticks * 10000 + JavaScriptSerializer.DatetimeMinTimeTicks, DateTimeKind.Utc);
Script\Serialization\JavaScriptSerializer.cs (1)
211internal static readonly long DatetimeMinTimeTicks = (new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Utc)).Ticks;
Script\Services\WebServiceClientProxyGenerator.cs (1)
29return new DateTime(writeTime.Year, writeTime.Month, writeTime.Day, writeTime.Hour, writeTime.Minute, writeTime.Second);
System.Web.Mobile (6)
UI\MobileControls\Adapters\ChtmlCalendarAdapter.cs (2)
210Control.VisibleDate = new DateTime(Int64.Parse((String)triplet.Third, CultureInfo.InvariantCulture)); 217Control.VisibleDate = new DateTime(Int64.Parse((String)viewState[2], CultureInfo.InvariantCulture));
UI\MobileControls\Adapters\WmlCalendarAdapter.cs (2)
192Control.VisibleDate = new DateTime(Int64.Parse((String)triplet.Third, CultureInfo.InvariantCulture)); 199Control.VisibleDate = new DateTime(Int64.Parse((String)viewState[2], CultureInfo.InvariantCulture));
UI\MobileControls\Adapters\XhtmlAdapters\XhtmlBasicCalendarAdapter.cs (2)
181Control.VisibleDate = new DateTime(Int64.Parse((String)triplet.Third, CultureInfo.InvariantCulture)); 187Control.VisibleDate = new DateTime(Int64.Parse((String)viewState[2], CultureInfo.InvariantCulture));
System.Windows.Forms (5)
winforms\Managed\System\WinForms\DateTimePicker.cs (4)
80public static readonly DateTime MinDateTime = new DateTime(1753, 1, 1); 87public static readonly DateTime MaxDateTime = new DateTime(9998, 12, 31); 815return new DateTime(1753, 1, 1); 1729return new DateTime(s.wYear, s.wMonth, s.wDay, s.wHour, s.wMinute, s.wSecond);
winforms\Managed\System\WinForms\NativeMethods.cs (1)
4523return new DateTime(longVal);
System.Windows.Forms.DataVisualization (21)
Common\DataManager\DataPoint.cs (4)
2128 DateTime time = new DateTime( 2140 DateTime time = new DateTime( 2296 DateTime date = new DateTime( 2317 DateTime time = new DateTime(
Common\General\ChartElement.cs (16)
987 DateTime sizeAdjustedDate = new DateTime(newStartDate.Year, 1, 1, 0, 0, 0); 1008 newStartDate = new DateTime(year, 1018 newStartDate = new DateTime(newStartDate.Year, 1028 newStartDate = new DateTime(newStartDate.Year, 1034 newStartDate = new DateTime(newStartDate.Year, 1040 newStartDate = new DateTime(newStartDate.Year, 1050 newStartDate = new DateTime(newStartDate.Year, 1061 newStartDate = new DateTime(newStartDate.Year, 1077 newStartDate = new DateTime(newStartDate.Year, 1202 roundedDateValue = new DateTime(dateValue.Year, 1207 roundedDateValue = new DateTime(dateValue.Year, 1212 roundedDateValue = new DateTime(dateValue.Year, 1217 roundedDateValue = new DateTime(dateValue.Year, 1223 roundedDateValue = new DateTime(dateValue.Year, 1232 roundedDateValue = new DateTime(dateValue.Year, 1242 roundedDateValue = new DateTime(dateValue.Year,
Common\Utilities\XmlSerializer.cs (1)
3130 objValue = new DateTime(reader.ReadInt64());
System.Xml (29)
System\Xml\BinaryXml\SqlUtils.cs (8)
756return new DateTime(yr, mnth, day, hr, min, sec, ms, DateTimeKind.Utc); 770DateTime d = new DateTime(yr, mnth, day, 0, 0, 0, DateTimeKind.Utc); 787return new DateTime(1, 1, 1, hr, min, sec, ms, DateTimeKind.Utc); 796DateTime SQLBaseDate = new DateTime(1900, 1, 1); 823DateTime dt = new DateTime(dateTicks); 831DateTime dt = new DateTime(dateTicks + timeTicks); 978return (int)(dt.Ticks - new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second).Ticks); 982return (int)(dt.Ticks - new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second).Ticks);
System\Xml\Schema\XsdDateTime.cs (16)
139dt = new DateTime(parser.year, parser.month, parser.day, parser.hour, parser.minute, parser.second); 315get { return (int)(dt.Ticks - new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second).Ticks); } 345return new DateTime(dt.Ticks, DateTimeKind.Utc); 348return new DateTime(dt.Subtract(new TimeSpan(ZoneHour, ZoneMinute, 0)).Ticks, DateTimeKind.Utc); 351return new DateTime(dt.Add(new TimeSpan(ZoneHour, ZoneMinute, 0)).Ticks, DateTimeKind.Utc); 382result = new DateTime(DateTime.Now.Year, xdt.Month, xdt.Day); 387TimeSpan addDiff = new DateTime(currentDateTime.Year, currentDateTime.Month, currentDateTime.Day) - new DateTime(xdt.Year, xdt.Month, xdt.Day); 399result = new DateTime(result.Ticks, DateTimeKind.Utc); 410return new DateTime(ticks, DateTimeKind.Local); 412result = new DateTime(ticks, DateTimeKind.Utc).ToLocalTime(); 423return new DateTime(ticks, DateTimeKind.Local); 425result = new DateTime(ticks, DateTimeKind.Utc).ToLocalTime(); 439dt = new DateTime( DateTime.Now.Year, xdt.Month, xdt.Day ); 444TimeSpan addDiff = new DateTime(currentDateTime.Year, currentDateTime.Month, currentDateTime.Day) - new DateTime(xdt.Year, xdt.Month, xdt.Day);
System\Xml\Serialization\XmlCodeExporter.cs (1)
259ticks = (new DateTime(dt.Year, dt.Month, dt.Day)).Ticks;
System\Xml\XmlConvert.cs (4)
783value = new DateTime(value.Ticks, DateTimeKind.Unspecified); 1279dt = new DateTime(dt.Ticks, DateTimeKind.Unspecified); 1347return new DateTime(value.Ticks, DateTimeKind.Local); 1361return new DateTime(value.Ticks, DateTimeKind.Utc);
WindowsBase (3)
Base\MS\Internal\IO\Zip\ZipIOBlockManager.cs (1)
521return new DateTime(year, month,day,hours,minutes,seconds);
Base\MS\Internal\Security\RightsManagement\NativeRightsManagementAPIsStructures.cs (1)
107return new DateTime(Year, Month, Day,
Shared\MS\Win32\NativeMethodsCLR.cs (1)
4835return new DateTime(longVal);
5241 references to DateTime
mscorlib (881)
microsoft\win32\oavariantlib.cs (1)
54typeof(DateTime),
system\boolean.cs (1)
301DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\byte.cs (1)
254DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\char.cs (1)
499DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\convert.cs (39)
132(RuntimeType)typeof(DateTime), 468public static bool ToBoolean(DateTime value) 583public static char ToChar(DateTime value) 698public static sbyte ToSByte(DateTime value) 800public static byte ToByte(DateTime value) 899public static short ToInt16(DateTime value) 1014public static ushort ToUInt16(DateTime value) 1124public static int ToInt32(DateTime value) 1242public static uint ToUInt32(DateTime value) 1332public static long ToInt64(DateTime value) 1441public static ulong ToUInt64(DateTime value) 1529public static float ToSingle(DateTime value) 1616public static double ToDouble(DateTime value) 1702public static decimal ToDecimal(DateTime value) 1712public static DateTime ToDateTime(DateTime value) { 1716public static DateTime ToDateTime(object value) { 1717return value == null? DateTime.MinValue: ((IConvertible)value).ToDateTime(null); 1720public static DateTime ToDateTime(object value, IFormatProvider provider) { 1721return value == null? DateTime.MinValue: ((IConvertible)value).ToDateTime(provider); 1724public static DateTime ToDateTime(String value) { 1727return DateTime.Parse(value, CultureInfo.CurrentCulture); 1730public static DateTime ToDateTime(String value, IFormatProvider provider) { 1733return DateTime.Parse(value, provider); 1737public static DateTime ToDateTime(sbyte value) { 1741public static DateTime ToDateTime(byte value) { 1745public static DateTime ToDateTime(short value) { 1750public static DateTime ToDateTime(ushort value) { 1754public static DateTime ToDateTime(int value) { 1759public static DateTime ToDateTime(uint value) { 1763public static DateTime ToDateTime(long value) { 1768public static DateTime ToDateTime(ulong value) { 1772public static DateTime ToDateTime(bool value) { 1776public static DateTime ToDateTime(char value) { 1780public static DateTime ToDateTime(float value) { 1784public static DateTime ToDateTime(double value) { 1788public static DateTime ToDateTime(decimal value) { 1949public static string ToString(DateTime value) { 1954public static string ToString(DateTime value, IFormatProvider provider) {
system\currenttimezone.cs (19)
95internal long GetUtcOffsetFromUniversalTime(DateTime time, ref Boolean isAmbiguousLocalDst) { 108DateTime startTime = daylightTime.Start - offset; 109DateTime endTime = daylightTime.End - offset - daylightTime.Delta; 110DateTime ambiguousStart; 111DateTime ambiguousEnd; 142public override DateTime ToLocalTime(DateTime time) { 149if (tick>DateTime.MaxTicks) { 150return new DateTime(DateTime.MaxTicks, DateTimeKind.Local); 152if (tick<DateTime.MinTicks) { 153return new DateTime(DateTime.MinTicks, DateTimeKind.Local); 200m_CachedDaylightChanges.Add(objYear, new DaylightTime(DateTime.MinValue, DateTime.MinValue, TimeSpan.Zero)); 202DateTime start; 203DateTime end; 234public override TimeSpan GetUtcOffset(DateTime time) { 246private static DateTime GetDayOfWeek(int year, bool fixedDate, int month, int targetDayOfWeek, int numberOfSunday, int hour, int minute, int second, int millisecond) { 247DateTime time; 257int day = DateTime.DaysInMonth(year, month);
system\datetime.cs (94)
57public struct DateTime : IComparable, IFormattable, IConvertible, ISerializable, IComparable<DateTime>,IEquatable<DateTime> { 116public static readonly DateTime MinValue = new DateTime(MinTicks, DateTimeKind.Unspecified); 117public static readonly DateTime MaxValue = new DateTime(MaxTicks, DateTimeKind.Unspecified); 245DateTime dt = new DateTime(dateData); 329DateTime dt = new DateTime(dateData); 364DateTime dt = new DateTime(dateData); 432public DateTime Add(TimeSpan value) { 438private DateTime Add(double value, int scale) { 451public DateTime AddDays(double value) { 461public DateTime AddHours(double value) { 471public DateTime AddMilliseconds(double value) { 481public DateTime AddMinutes(double value) { 502public DateTime AddMonths(int months) { 532public DateTime AddSeconds(double value) { 540public DateTime AddTicks(long value) { 556public DateTime AddYears(int value) { 565public static int Compare(DateTime t1, DateTime t2) { 581if (!(value is DateTime)) { 585long valueTicks = ((DateTime)value).InternalTicks; 592public int CompareTo(DateTime value) { 682if (value is DateTime) { 683return InternalTicks == ((DateTime)value).InternalTicks; 688public bool Equals(DateTime value) { 696public static bool Equals(DateTime t1, DateTime t2) { 700public static DateTime FromBinary(Int64 dateData) { 716offsetTicks = TimeZoneInfo.GetLocalUtcOffset(DateTime.MinValue, TimeZoneInfoOptions.NoThrowOnInvalidTime).Ticks; 719offsetTicks = TimeZoneInfo.GetLocalUtcOffset(DateTime.MaxValue, TimeZoneInfoOptions.NoThrowOnInvalidTime).Ticks; 724DateTime utcDt = new DateTime(ticks, DateTimeKind.Utc); 740return DateTime.FromBinaryRaw(dateData); 746internal static DateTime FromBinaryRaw(Int64 dateData) { 757public static DateTime FromFileTime(long fileTime) { 761public static DateTime FromFileTimeUtc(long fileTime) { 779public static DateTime FromOADate(double d) { 804public static DateTime SpecifyKind(DateTime value, DateTimeKind kind) { 843public DateTime Date { 1051public static DateTime Now { 1053Contract.Ensures(Contract.Result<DateTime>().Kind == DateTimeKind.Local); 1055DateTime utc = UtcNow; 1059if (tick>DateTime.MaxTicks) { 1060return new DateTime(DateTime.MaxTicks, DateTimeKind.Local); 1062if (tick<DateTime.MinTicks) { 1063return new DateTime(DateTime.MinTicks, DateTimeKind.Local); 1069public static DateTime UtcNow { 1072Contract.Ensures(Contract.Result<DateTime>().Kind == DateTimeKind.Utc); 1117DateTime dt = new DateTime(ticks); 1176internal static DateTime InternalFromFileTime(long fileTime) 1204internal static DateTime CreateDateTimeFromSystemTime(ref FullSystemTime time) 1216DateTime dt = new DateTime(year, month, day); 1262public static DateTime Today { 1264return DateTime.Now.Date; 1293public static DateTime Parse(String s) { 1301public static DateTime Parse(String s, IFormatProvider provider) { 1305public static DateTime Parse(String s, IFormatProvider provider, DateTimeStyles styles) { 1314public static DateTime ParseExact(String s, String format, IFormatProvider provider) { 1322public static DateTime ParseExact(String s, String format, IFormatProvider provider, DateTimeStyles style) { 1327public static DateTime ParseExact(String s, String[] formats, IFormatProvider provider, DateTimeStyles style) { 1332public TimeSpan Subtract(DateTime value) { 1336public DateTime Subtract(TimeSpan value) { 1391public DateTime ToLocalTime() 1396internal DateTime ToLocalTime(bool throwOnOverflow) 1405if (tick > DateTime.MaxTicks) 1410return new DateTime(DateTime.MaxTicks, DateTimeKind.Local); 1412if (tick < DateTime.MinTicks) 1417return new DateTime(DateTime.MinTicks, DateTimeKind.Local); 1462public DateTime ToUniversalTime() { 1466public static Boolean TryParse(String s, out DateTime result) { 1470public static Boolean TryParse(String s, IFormatProvider provider, DateTimeStyles styles, out DateTime result) { 1475public static Boolean TryParseExact(String s, String format, IFormatProvider provider, DateTimeStyles style, out DateTime result) { 1480public static Boolean TryParseExact(String s, String[] formats, IFormatProvider provider, DateTimeStyles style, out DateTime result) { 1485public static DateTime operator +(DateTime d, TimeSpan t) { 1494public static DateTime operator -(DateTime d, TimeSpan t) { 1503public static TimeSpan operator -(DateTime d1, DateTime d2) { 1507public static bool operator ==(DateTime d1, DateTime d2) { 1511public static bool operator !=(DateTime d1, DateTime d2) { 1515public static bool operator <(DateTime t1, DateTime t2) { 1519public static bool operator <=(DateTime t1, DateTime t2) { 1523public static bool operator >(DateTime t1, DateTime t2) { 1527public static bool operator >=(DateTime t1, DateTime t2) { 1644DateTime IConvertible.ToDateTime(IFormatProvider provider) { 1656internal static Boolean TryCreate(int year, int month, int day, int hour, int minute, int second, int millisecond, out DateTime result) { 1657result = DateTime.MinValue;
system\datetimeoffset.cs (49)
45private const long UnixEpochTicks = TimeSpan.TicksPerDay * DateTime.DaysTo1970; // 621,355,968,000,000,000 50public static readonly DateTimeOffset MinValue = new DateTimeOffset(DateTime.MinTicks, TimeSpan.Zero); 51public static readonly DateTimeOffset MaxValue = new DateTimeOffset(DateTime.MaxTicks, TimeSpan.Zero); 54private DateTime m_dateTime; 63DateTime dateTime = new DateTime(ticks); 69public DateTimeOffset(DateTime dateTime) { 85public DateTimeOffset(DateTime dateTime, TimeSpan offset) { 106if (second == 60 && DateTime.s_isLeapSecondsSupportedSystem) 114!DateTime.IsValidTimeWithLeapSeconds(m_dateTime.Year, m_dateTime.Month, m_dateTime.Day, m_dateTime.Hour, m_dateTime.Minute, 60, DateTimeKind.Utc)) 126if (second == 60 && DateTime.s_isLeapSecondsSupportedSystem) 135!DateTime.IsValidTimeWithLeapSeconds(m_dateTime.Year, m_dateTime.Month, m_dateTime.Day, m_dateTime.Hour, m_dateTime.Minute, 60, DateTimeKind.Utc)) 148if (second == 60 && DateTime.s_isLeapSecondsSupportedSystem) 157!DateTime.IsValidTimeWithLeapSeconds(m_dateTime.Year, m_dateTime.Month, m_dateTime.Day, m_dateTime.Hour, m_dateTime.Minute, 60, DateTimeKind.Utc)) 171return new DateTimeOffset(DateTime.Now); 177return new DateTimeOffset(DateTime.UtcNow); 181public DateTime DateTime { 187public DateTime UtcDateTime { 190Contract.Ensures(Contract.Result<DateTime>().Kind == DateTimeKind.Utc); 191return DateTime.SpecifyKind(m_dateTime, DateTimeKind.Utc); 195public DateTime LocalDateTime { 198Contract.Ensures(Contract.Result<DateTime>().Kind == DateTimeKind.Local); 215private DateTime ClockDateTime { 225public DateTime Date { 447return DateTime.Compare(first.UtcDateTime, second.UtcDateTime); 461DateTime objUtc = ((DateTimeOffset)obj).UtcDateTime; 462DateTime utc = UtcDateTime; 469DateTime otherUtc = other.UtcDateTime; 470DateTime utc = UtcDateTime; 508return DateTime.Equals(first.UtcDateTime, second.UtcDateTime); 516return new DateTimeOffset(DateTime.FromFileTime(fileTime)); 520const long MinSeconds = DateTime.MinTicks / TimeSpan.TicksPerSecond - UnixEpochSeconds; 521const long MaxSeconds = DateTime.MaxTicks / TimeSpan.TicksPerSecond - UnixEpochSeconds; 533const long MinMilliseconds = DateTime.MinTicks / TimeSpan.TicksPerMillisecond - UnixEpochMilliseconds; 534const long MaxMilliseconds = DateTime.MaxTicks / TimeSpan.TicksPerMillisecond - UnixEpochMilliseconds; 577m_dateTime = (DateTime)info.GetValue("DateTime", typeof(DateTime)); 594DateTime dateResult = DateTimeParse.Parse(input, 612DateTime dateResult = DateTimeParse.Parse(input, 634DateTime dateResult = DateTimeParse.ParseExact(input, 645DateTime dateResult = DateTimeParse.ParseExactMultiple(input, 729DateTime dateResult; 742DateTime dateResult; 756DateTime dateResult; 771DateTime dateResult; 795private static DateTime ValidateDate(DateTime dateTime, TimeSpan offset) { 802if (utcTicks < DateTime.MinTicks || utcTicks > DateTime.MaxTicks) { 833public static implicit operator DateTimeOffset (DateTime dateTime) {
system\dbnull.cs (1)
113DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\decimal.cs (1)
1267DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\deployment\isolationinterop.cs (1)
1352public StoreOperationPinDeployment(IDefinitionAppId AppId, System.DateTime Expiry, StoreApplicationReference Ref)
system\diagnostics\eventing\eventprovider.cs (3)
824else if (data is DateTime) 830if (((DateTime)data).Ticks > UTCMinTicks) 831dateTimeTicks = ((DateTime)data).ToFileTimeUtc();
system\diagnostics\eventing\eventsource.cs (2)
1841else if (dataType == typeof(DateTime)) 1844return DateTime.FromFileTimeUtc(dateTimeTicks);
System\Diagnostics\Eventing\TraceLogging\SimpleTypeInfos.cs (2)
891: TraceLoggingTypeInfo<DateTime> 901public override void WriteData(TraceLoggingDataCollector collector, ref DateTime value)
System\Diagnostics\Eventing\TraceLogging\Statics.cs (1)
761else if (dataType == typeof(DateTime))
system\double.cs (1)
368DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\enum.cs (1)
1030DateTime IConvertible.ToDateTime(IFormatProvider provider)
system\globalization\calendar.cs (41)
102public virtual DateTime MinSupportedDateTime 106return (DateTime.MinValue); 113public virtual DateTime MaxSupportedDateTime 117return (DateTime.MaxValue); 246internal static void CheckAddResult(long ticks, DateTime minValue, DateTime maxValue) { 255internal DateTime Add(DateTime time, double value, int scale) { 282public virtual DateTime AddMilliseconds(DateTime time, double milliseconds) { 294public virtual DateTime AddDays(DateTime time, int days) { 305public virtual DateTime AddHours(DateTime time, int hours) { 317public virtual DateTime AddMinutes(DateTime time, int minutes) { 340public abstract DateTime AddMonths(DateTime time, int months); 349public virtual DateTime AddSeconds(DateTime time, int seconds) { 358public virtual DateTime AddWeeks(DateTime time, int weeks) { 372public abstract DateTime AddYears(DateTime time, int years); 378public abstract int GetDayOfMonth(DateTime time); 386public abstract DayOfWeek GetDayOfWeek(DateTime time); 392public abstract int GetDayOfYear(DateTime time); 424public abstract int GetEra(DateTime time); 444public virtual int GetHour(DateTime time) { 452public virtual double GetMilliseconds(DateTime time) { 460public virtual int GetMinute(DateTime time) { 468public abstract int GetMonth(DateTime time); 485public virtual int GetSecond(DateTime time) { 526internal int GetFirstDayWeekOfYear(DateTime time, int firstDayOfWeek) { 537private int GetWeekOfYearFullDays(DateTime time, int firstDayOfWeek, int fullDays) { 651public virtual int GetWeekOfYear(DateTime time, CalendarWeekRule rule, DayOfWeek firstDayOfWeek) 677public abstract int GetYear(DateTime time); 756public virtual DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond) 764public abstract DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era); 766internal virtual Boolean TryToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era, out DateTime result) { 767result = DateTime.MinValue;
system\globalization\CalendricalCalculationsHelper.cs (2)
70internal static long GetNumberOfDays(DateTime date) 77return new DateTime(Math.Min((long)(Math.Floor(numberOfDays) * GregorianCalendar.TicksPerDay), DateTime.MaxValue.Ticks)).Year;
system\globalization\chineselunisolarcalendar.cs (8)
45internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 46internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999); 49public override DateTime MinSupportedDateTime { 58public override DateTime MaxSupportedDateTime { 295internal override DateTime MinDate { 302internal override DateTime MaxDate { 329internal override int GetYear(int year, DateTime time) { 376public override int GetEra(DateTime time) {
system\globalization\datetimeformat.cs (17)
278private static String FormatHebrewMonthName(DateTime time, int month, int repeatCount, DateTimeFormatInfo dtfi) 434private static String FormatCustomized(DateTime dateTime, String format, DateTimeFormatInfo dtfi, TimeSpan offset) { 717private static void FormatCustomizedTimeZone(DateTime dateTime, TimeSpan offset, String format, Int32 tokenLen, Boolean timeOnly, StringBuilder result) { 726offset = TimeZoneInfo.GetLocalUtcOffset(DateTime.Now, TimeZoneInfoOptions.NoThrowOnInvalidTime); 737dateTime = DateTime.SpecifyKind(dateTime, DateTimeKind.Local); 768private static void FormatCustomizedRoundripTimeZone(DateTime dateTime, TimeSpan offset, StringBuilder result) { 871private static String ExpandPredefinedFormat(String format, ref DateTime dateTime, ref DateTimeFormatInfo dtfi, ref TimeSpan offset) { 907internal static String Format(DateTime dateTime, String format, DateTimeFormatInfo dtfi) { 912internal static String Format(DateTime dateTime, String format, DateTimeFormatInfo dtfi, TimeSpan offset) 982internal static StringBuilder FastFormatRfc1123(DateTime dateTime, TimeSpan offset, DateTimeFormatInfo dtfi) 1013internal static StringBuilder FastFormatRoundtrip(DateTime dateTime, TimeSpan offset) 1039private static void AppendHHmmssTimeOfDay(StringBuilder result, DateTime dateTime) 1067internal static String[] GetAllDateTimes(DateTime dateTime, char format, DateTimeFormatInfo dtfi) 1095DateTime universalTime = dateTime.ToUniversalTime(); 1122internal static String[] GetAllDateTimes(DateTime dateTime, DateTimeFormatInfo dtfi) 1141internal static void InvalidFormatForLocal(String format, DateTime dateTime) { 1147internal static void InvalidFormatForUtc(String format, DateTime dateTime) {
system\globalization\datetimeformatinfo.cs (1)
196ret = DateTime.LegacyParseMode();
system\globalization\datetimeparse.cs (41)
44return DateTime.EnableAmPmParseAdjustment(); 50internal static DateTime ParseExact(String s, String format, DateTimeFormatInfo dtfi, DateTimeStyles style) { 61internal static DateTime ParseExact(String s, String format, DateTimeFormatInfo dtfi, DateTimeStyles style, out TimeSpan offset) { 75internal static bool TryParseExact(String s, String format, DateTimeFormatInfo dtfi, DateTimeStyles style, out DateTime result) { 76result = DateTime.MinValue; 86internal static bool TryParseExact(String s, String format, DateTimeFormatInfo dtfi, DateTimeStyles style, out DateTime result, out TimeSpan offset) { 87result = DateTime.MinValue; 124internal static DateTime ParseExactMultiple(String s, String[] formats, 137internal static DateTime ParseExactMultiple(String s, String[] formats, 153DateTimeFormatInfo dtfi, DateTimeStyles style, out DateTime result, out TimeSpan offset) { 154result = DateTime.MinValue; 169DateTimeFormatInfo dtfi, DateTimeStyles style, out DateTime result) { 170result = DateTime.MinValue; 2275internal static DateTime Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles) { 2286internal static DateTime Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles, out TimeSpan offset) { 2300internal static bool TryParse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles, out DateTime result) { 2301result = DateTime.MinValue; 2311internal static bool TryParse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles, out DateTime result, out TimeSpan offset) { 2312result = DateTime.MinValue; 2346DateTime time; 2594result.parsedDate = DateTime.SpecifyKind(result.parsedDate, DateTimeKind.Local); 2600result.parsedDate = DateTime.SpecifyKind(result.parsedDate, DateTimeKind.Utc); 2616result.parsedDate = DateTime.SpecifyKind(result.parsedDate, DateTimeKind.Utc); 2650if (utcTicks < DateTime.MinTicks || utcTicks > DateTime.MaxTicks) { 2694if (resultTicks < DateTime.MinTicks || resultTicks > DateTime.MaxTicks) { 2722resultTicks += tz.GetUtcOffset(bTimeOnly ? DateTime.Now: result.parsedDate, TimeZoneInfoOptions.NoThrowOnInvalidTime).Ticks; 2730if (resultTicks < DateTime.MinTicks || resultTicks > DateTime.MaxTicks) { 2736DateTime utcDt = new DateTime(resultTicks, DateTimeKind.Utc); 2741if (resultTicks < DateTime.MinTicks || resultTicks > DateTime.MaxTicks) { 2742result.parsedDate = DateTime.MinValue; 2829DateTime time; 3344private static DateTime GetDateTimeNow(ref DateTimeResult result, ref DateTimeStyles styles) { 3348return new DateTime(DateTime.UtcNow.Ticks + result.timeZoneOffset.Ticks, DateTimeKind.Unspecified); 3352return DateTime.UtcNow; 3357return DateTime.Now; 3402DateTime now = GetDateTimeNow(ref result, ref styles); 5008internal DateTime parsedDate;
system\globalization\daylighttime.cs (10)
14internal DateTime m_start; 15internal DateTime m_end; 21public DaylightTime(DateTime start, DateTime end, TimeSpan delta) { 28public DateTime Start { 35public DateTime End { 53public DaylightTimeStruct(DateTime start, DateTime end, TimeSpan delta) 60public DateTime Start { get; } 61public DateTime End { get; }
system\globalization\eastasianlunisolarcalendar.cs (19)
53public virtual int GetSexagenaryYear (DateTime time) { 93internal abstract int GetYear(int year, DateTime time); 99internal abstract DateTime MinDate {get;} 100internal abstract DateTime MaxDate {get;} 234public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) { 374internal DateTime LunarToTime(DateTime time, int year, int month, int day) { 380internal void TimeToLunar(DateTime time, ref int year, ref int month, ref int day) { 400public override DateTime AddMonths(DateTime time, int months) { 437DateTime dt = LunarToTime(time, y, m, d); 444public override DateTime AddYears(DateTime time, int years) { 461DateTime dt = LunarToTime(time, y, m, d); 470public override int GetDayOfYear(DateTime time) { 487public override int GetDayOfMonth(DateTime time) { 515public override int GetMonth(DateTime time) { 528public override int GetYear(DateTime time) { 543public override DayOfWeek GetDayOfWeek(DateTime time) {
system\globalization\gregoriancalendar.cs (18)
82public override DateTime MinSupportedDateTime 86return (DateTime.MinValue); 91public override DateTime MaxSupportedDateTime 95return (DateTime.MaxValue); 285public override DateTime AddMonths(DateTime time, int months) 335public override DateTime AddYears(DateTime time, int years) 344public override int GetDayOfMonth(DateTime time) 355public override DayOfWeek GetDayOfWeek(DateTime time) 364public override int GetDayOfYear(DateTime time) 410public override int GetEra(DateTime time) 427public override int GetMonth(DateTime time) 456public override int GetYear(DateTime time) 567public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) 575internal override Boolean TryToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era, out DateTime result) { 577return DateTime.TryCreate(year, month, day, hour, minute, second, millisecond, out result); 579result = DateTime.MinValue;
system\globalization\gregoriancalendarhelper.cs (14)
132internal DateTime m_minDate; 383public DateTime AddMonths(DateTime time, int months) 431public DateTime AddYears(DateTime time, int years) 439public int GetDayOfMonth(DateTime time) 449public DayOfWeek GetDayOfWeek(DateTime time) 458public int GetDayOfYear(DateTime time) 492public int GetEra(DateTime time) 520public int GetMonth(DateTime time) 535public int GetYear(DateTime time) 550public int GetYear(int year, DateTime time) 626public DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) { 633public virtual int GetWeekOfYear(DateTime time, CalendarWeekRule rule, DayOfWeek firstDayOfWeek) {
system\globalization\hebrewcalendar.cs (20)
296internal static readonly DateTime calendarMinValue = new DateTime(1583, 1, 1); 299internal static readonly DateTime calendarMaxValue = new DateTime((new DateTime(2239, 9, 29, 23, 59, 59, 999)).Ticks + 9999); 303public override DateTime MinSupportedDateTime 313public override DateTime MaxSupportedDateTime 544DateTime time = new DateTime(ticks); 666public override DateTime AddMonths(DateTime time, int months) { 723public override DateTime AddYears(DateTime time, int years) { 750public override int GetDayOfMonth(DateTime time) { 760public override DayOfWeek GetDayOfWeek(DateTime time) { 777public override int GetDayOfYear(DateTime time) { 780DateTime beginOfYearDate; 841public override int GetEra(DateTime time) { 857public override int GetMonth(DateTime time) { 871public override int GetYear(DateTime time) { 994static DateTime HebrewToGregorian(int hebrewYear, int hebrewMonth, int hebrewDay, int hour, int minute, int second, int millisecond) { 1008DateTime gregorianNewYear = new DateTime(gregorianYear, 1, 1); 1016public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) { 1020DateTime dt = HebrewToGregorian(year, month, day, hour, minute, second, millisecond);
system\globalization\hijricalendar.cs (16)
86internal static readonly DateTime calendarMinValue = new DateTime(622, 7, 18); 87internal static readonly DateTime calendarMaxValue = DateTime.MaxValue; 91public override DateTime MinSupportedDateTime 101public override DateTime MaxSupportedDateTime 500public override DateTime AddMonths(DateTime time, int months) { 541public override DateTime AddYears(DateTime time, int years) { 549public override int GetDayOfMonth(DateTime time) { 559public override DayOfWeek GetDayOfWeek(DateTime time) { 567public override int GetDayOfYear(DateTime time) { 596public override int GetEra(DateTime time) { 612public override int GetMonth(DateTime time) { 627public override int GetYear(DateTime time) { 682public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) {
system\globalization\japanesecalendar.cs (16)
48internal static readonly DateTime calendarMinValue = new DateTime(1868, 9, 8); 52public override DateTime MinSupportedDateTime 61public override DateTime MaxSupportedDateTime 65return (DateTime.MaxValue); 368public override DateTime AddMonths(DateTime time, int months) { 373public override DateTime AddYears(DateTime time, int years) { 399public override int GetDayOfMonth(DateTime time) { 404public override DayOfWeek GetDayOfWeek(DateTime time) { 409public override int GetDayOfYear(DateTime time) 423public override int GetWeekOfYear(DateTime time, CalendarWeekRule rule, DayOfWeek firstDayOfWeek) 437public override int GetEra(DateTime time) { 442public override int GetMonth(DateTime time) { 447public override int GetYear(DateTime time) { 478public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) {
system\globalization\japaneselunisolarcalendar.cs (8)
45internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 46internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999); 48public override DateTime MinSupportedDateTime 57public override DateTime MaxSupportedDateTime 182internal override DateTime MinDate { 189internal override DateTime MaxDate { 218internal override int GetYear(int year, DateTime time) { 271public override int GetEra(DateTime time) {
system\globalization\juliancalendar.cs (15)
56public override DateTime MinSupportedDateTime 60return (DateTime.MinValue); 65public override DateTime MaxSupportedDateTime 69return (DateTime.MaxValue); 230public override DateTime AddMonths(DateTime time, int months) 266public override DateTime AddYears(DateTime time, int years) { 271public override int GetDayOfMonth(DateTime time) { 276public override DayOfWeek GetDayOfWeek(DateTime time) { 281public override int GetDayOfYear(DateTime time) { 300public override int GetEra(DateTime time) 306public override int GetMonth(DateTime time) 326public override int GetYear(DateTime time) 374public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era)
system\globalization\koreancalendar.cs (16)
54public override DateTime MinSupportedDateTime 58return (DateTime.MinValue); 63public override DateTime MaxSupportedDateTime 67return (DateTime.MaxValue); 116public override DateTime AddMonths(DateTime time, int months) { 121public override DateTime AddYears(DateTime time, int years) { 147public override int GetDayOfMonth(DateTime time) { 152public override DayOfWeek GetDayOfWeek(DateTime time) { 157public override int GetDayOfYear(DateTime time) 170public override int GetWeekOfYear(DateTime time, CalendarWeekRule rule, DayOfWeek firstDayOfWeek) 176public override int GetEra(DateTime time) { 180public override int GetMonth(DateTime time) { 185public override int GetYear(DateTime time) { 216public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) {
system\globalization\koreanlunisolarcalendar.cs (8)
46internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 47internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999); 49public override DateTime MinSupportedDateTime { 58public override DateTime MaxSupportedDateTime { 1228internal override DateTime MinDate { 1235internal override DateTime MaxDate { 1263internal override int GetYear(int year, DateTime time) 1310public override int GetEra(DateTime time) {
system\globalization\Persiancalendar.cs (16)
50internal static DateTime minDate = new DateTime(622, 3, 22); 51internal static DateTime maxDate = DateTime.MaxValue; 71public override DateTime MinSupportedDateTime 80public override DateTime MaxSupportedDateTime 291public override DateTime AddMonths(DateTime time, int months) { 333public override DateTime AddYears(DateTime time, int years) { 342public override int GetDayOfMonth(DateTime time) { 353public override DayOfWeek GetDayOfWeek(DateTime time) { 362public override int GetDayOfYear(DateTime time) { 402public override int GetEra(DateTime time) { 420public override int GetMonth(DateTime time) { 440public override int GetYear(DateTime time) { 504public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) {
system\globalization\taiwancalendar.cs (16)
63internal static readonly DateTime calendarMinValue = new DateTime(1912, 1, 1); 67public override DateTime MinSupportedDateTime 76public override DateTime MaxSupportedDateTime 80return (DateTime.MaxValue); 113public override DateTime AddMonths(DateTime time, int months) { 118public override DateTime AddYears(DateTime time, int years) { 133public override int GetDayOfMonth(DateTime time) { 138public override DayOfWeek GetDayOfWeek(DateTime time) { 143public override int GetDayOfYear(DateTime time) 156public override int GetWeekOfYear(DateTime time, CalendarWeekRule rule, DayOfWeek firstDayOfWeek) 162public override int GetEra(DateTime time) { 166public override int GetMonth(DateTime time) { 171public override int GetYear(DateTime time) { 202public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) {
system\globalization\taiwanlunisolarcalendar.cs (8)
51internal static DateTime minDate = new DateTime(MIN_GREGORIAN_YEAR, MIN_GREGORIAN_MONTH, MIN_GREGORIAN_DAY); 52internal static DateTime maxDate = new DateTime((new DateTime(MAX_GREGORIAN_YEAR, MAX_GREGORIAN_MONTH, MAX_GREGORIAN_DAY, 23, 59, 59, 999)).Ticks + 9999); 54public override DateTime MinSupportedDateTime { 63public override DateTime MaxSupportedDateTime { 238internal override DateTime MinDate { 245internal override DateTime MaxDate { 274internal override int GetYear(int year, DateTime time) { 307public override int GetEra(DateTime time) {
system\globalization\thaibuddhistcalendar.cs (16)
45public override DateTime MinSupportedDateTime 49return (DateTime.MinValue); 54public override DateTime MaxSupportedDateTime 58return (DateTime.MaxValue); 85public override DateTime AddMonths(DateTime time, int months) { 90public override DateTime AddYears(DateTime time, int years) { 105public override int GetDayOfMonth(DateTime time) { 110public override DayOfWeek GetDayOfWeek(DateTime time) { 115public override int GetDayOfYear(DateTime time) 128public override int GetWeekOfYear(DateTime time, CalendarWeekRule rule, DayOfWeek firstDayOfWeek) 134public override int GetEra(DateTime time) { 138public override int GetMonth(DateTime time) { 143public override int GetYear(DateTime time) { 174public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) {
system\globalization\umalquracalendar.cs (20)
38internal DateTime GregorianDate; 258internal static DateTime minDate = new DateTime(1900, 4, 30); 259internal static DateTime maxDate = new DateTime((new DateTime(2077, 11, 16, 23, 59, 59, 999)).Ticks + 9999); 279public override DateTime MinSupportedDateTime 288public override DateTime MaxSupportedDateTime 346DateTime dt; 424static void ConvertGregorianToHijri(DateTime time, ref int HijriYear, ref int HijriMonth, ref int HijriDay) 483internal virtual int GetDatePart(DateTime time, int part) { 527public override DateTime AddMonths(DateTime time, int months) { 560DateTime dt = new DateTime(GetAbsoluteDateUmAlQura(y, m, d) * TicksPerDay + time.Ticks % TicksPerDay); 575public override DateTime AddYears(DateTime time, int years) { 584public override int GetDayOfMonth(DateTime time) { 595public override DayOfWeek GetDayOfWeek(DateTime time) { 604public override int GetDayOfYear(DateTime time) { 659public override int GetEra(DateTime time) { 677public override int GetMonth(DateTime time) { 694public override int GetYear(DateTime time) { 763public override DateTime ToDateTime(int year, int month, int day, int hour, int minute, int second, int millisecond, int era) {
system\iconvertible.cs (1)
66DateTime ToDateTime(IFormatProvider provider);
system\int16.cs (1)
267DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\int32.cs (1)
240DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\int64.cs (1)
219DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\internal.cs (3)
99NullableHelper<DateTime>(); 113new List<DateTime>(); 137SZArrayHelper<DateTime>(null);
system\io\directory.cs (12)
453public static void SetCreationTime(String path,DateTime creationTime) 461public unsafe static void SetCreationTimeUtc(String path,DateTime creationTimeUtc) 476public static DateTime GetCreationTime(String path) 483public static DateTime GetCreationTimeUtc(String path) 490public static void SetLastWriteTime(String path,DateTime lastWriteTime) 498public unsafe static void SetLastWriteTimeUtc(String path,DateTime lastWriteTimeUtc) 513public static DateTime GetLastWriteTime(String path) 520public static DateTime GetLastWriteTimeUtc(String path) 527public static void SetLastAccessTime(String path,DateTime lastAccessTime) 535public unsafe static void SetLastAccessTimeUtc(String path,DateTime lastAccessTimeUtc) 550public static DateTime GetLastAccessTime(String path) 557public static DateTime GetLastAccessTimeUtc(String path)
system\io\file.cs (18)
485public static void SetCreationTime(String path, DateTime creationTime) 493public unsafe static void SetCreationTimeUtc(String path, DateTime creationTimeUtc) 510public static DateTime GetCreationTime(String path) 518public static DateTime GetCreationTimeUtc(String path) 526private static DateTime InternalGetCreationTimeUtc(String path, bool checkHost) 544return DateTime.FromFileTimeUtc(data.ftCreationTime.ToTicks()); 549public static void SetLastAccessTime(String path, DateTime lastAccessTime) 557public unsafe static void SetLastAccessTimeUtc(String path, DateTime lastAccessTimeUtc) 574public static DateTime GetLastAccessTime(String path) 582public static DateTime GetLastAccessTimeUtc(String path) 590private static DateTime InternalGetLastAccessTimeUtc(String path, bool checkHost) 608return DateTime.FromFileTimeUtc(data.ftLastAccessTime.ToTicks()); 613public static void SetLastWriteTime(String path, DateTime lastWriteTime) 621public unsafe static void SetLastWriteTimeUtc(String path, DateTime lastWriteTimeUtc) 638public static DateTime GetLastWriteTime(String path) 646public static DateTime GetLastWriteTimeUtc(String path) 654private static DateTime InternalGetLastWriteTimeUtc(String path, bool checkHost) 672return DateTime.FromFileTimeUtc(data.ftLastWriteTime.ToTicks());
system\io\filesysteminfo.cs (9)
153public DateTime CreationTime 166public DateTime CreationTimeUtc { 182return DateTime.FromFileTimeUtc(_data.ftCreationTime.ToTicks()); 198public DateTime LastAccessTime 210public DateTime LastAccessTimeUtc { 226return DateTime.FromFileTimeUtc(_data.ftLastAccessTime.ToTicks()); 240public DateTime LastWriteTime 253public DateTime LastWriteTimeUtc { 269return DateTime.FromFileTimeUtc(_data.ftLastWriteTime.ToTicks());
system\io\longpath.cs (6)
338DateTime dtLocal = DateTime.FromFileTimeUtc(data.ftCreationTime.ToTicks()).ToLocalTime(); 358DateTime dtLocal = DateTime.FromFileTimeUtc(data.ftLastAccessTime.ToTicks()).ToLocalTime(); 378DateTime dtLocal = DateTime.FromFileTimeUtc(data.ftLastWriteTime.ToTicks()).ToLocalTime();
system\reflection\emit\typebuilder.cs (2)
502else if (type == typeof(DateTime)) 505long ticks = ((DateTime)value).Ticks;
system\reflection\mdconstant.cs (1)
81else if (fieldType == typeof(DateTime))
system\reflection\parameterinfo.cs (1)
617if (ParameterType == typeof(DateTime))
system\resources\resourcereader.cs (2)
637else if (type == typeof(DateTime)) { 733return DateTime.FromBinary(data);
system\resources\resourcewriter.cs (2)
559else if (type == typeof(DateTime)) 664Int64 data = ((DateTime) value).ToBinary();
system\runtime\compilerservices\datetimeconstantattribute.cs (2)
29internal static DateTime GetRawDateTimeConstant(CustomAttributeData attr) 46private System.DateTime date;
system\Runtime\InteropServices\Variant.cs (3)
216*(double*)this._typeUnion._unionTypes._byref = ((DateTime)value).ToOADate(); 603public DateTime AsDate { 606return DateTime.FromOADate(_typeUnion._unionTypes._date);
system\runtime\remoting\lease.cs (9)
33internal DateTime leaseTime; 80leaseTime = DateTime.UtcNow.Add(initialLeaseTime); 156get { return leaseTime.Subtract(DateTime.UtcNow); } 265return leaseTime.Subtract(DateTime.UtcNow); 322internal void LeaseExpired(DateTime now) 555DateTime now = DateTime.UtcNow; 556DateTime oldLeaseTime = leaseTime; 557DateTime renewTime = now.Add(renewalSpan);
system\runtime\remoting\leasemanager.cs (10)
139internal void ChangedLeaseTime(Lease lease, DateTime newTime) 141BCLDebug.Trace("REMOTE","LeaseManager ChangedLeaseTime ",lease.id," ",lease.managedObject," newTime ",newTime," currentTime ", DateTime.UtcNow); 152internal DateTime sponsorWaitTime; 154internal SponsorInfo(Lease lease, Object sponsorId, DateTime sponsorWaitTime) 168DateTime sponsorWaitTime = DateTime.UtcNow.Add(sponsorshipTimeOut); 190DateTime now = DateTime.UtcNow; 197DateTime time = (DateTime)e.Value;
system\runtime\remoting\message.cs (1)
765else if (pt == typeof(DateTime))
system\runtime\remoting\soapinteroptypes.cs (43)
193public static String ToString(DateTime value) 199public static DateTime Parse(String value) 201DateTime dt; 205dt = DateTime.MinValue; 211dt = DateTime.ParseExact(time, formats, CultureInfo.InvariantCulture,DateTimeStyles.None); 396DateTime _value = DateTime.MinValue; 441public SoapTime(DateTime value) 447public DateTime Value 465SoapTime dt = new SoapTime(DateTime.ParseExact(time, formats, CultureInfo.InvariantCulture,DateTimeStyles.None)); 476DateTime _value = DateTime.MinValue.Date; 509public SoapDate(DateTime value) 515public SoapDate(DateTime value, int sign) 522public DateTime Value 550return new SoapDate(DateTime.ParseExact(value, formats, CultureInfo.InvariantCulture,DateTimeStyles.None), sign); 560DateTime _value = DateTime.MinValue; 592public SoapYearMonth(DateTime value) 598public SoapYearMonth(DateTime value, int sign) 606public DateTime Value 634return new SoapYearMonth(DateTime.ParseExact(value, formats, CultureInfo.InvariantCulture,DateTimeStyles.None), sign); 644DateTime _value = DateTime.MinValue; 676public SoapYear(DateTime value) 682public SoapYear(DateTime value, int sign) 690public DateTime Value 718return new SoapYear(DateTime.ParseExact(value, formats, CultureInfo.InvariantCulture,DateTimeStyles.None), sign); 727DateTime _value = DateTime.MinValue; 754public SoapMonthDay(DateTime value) 760public DateTime Value 775return new SoapMonthDay(DateTime.ParseExact(value, formats, CultureInfo.InvariantCulture,DateTimeStyles.None)); 784DateTime _value = DateTime.MinValue; 811public SoapDay(DateTime value) 817public DateTime Value 832return new SoapDay(DateTime.ParseExact(value, formats, CultureInfo.InvariantCulture,DateTimeStyles.None)); 841DateTime _value = DateTime.MinValue; 868public SoapMonth(DateTime value) 874public DateTime Value 889return new SoapMonth(DateTime.ParseExact(value, formats, CultureInfo.InvariantCulture,DateTimeStyles.None));
system\runtime\serialization\formatter.cs (2)
104protected abstract void WriteDateTime(DateTime val, String name); 159} else if (varType==typeof(DateTime)) {
system\runtime\serialization\formatterconverter.cs (1)
152public DateTime ToDateTime(Object value) {
system\runtime\serialization\formatters\binary\binaryconverter.cs (3)
316array = new DateTime[length]; 503internal static Type typeofDateTime = typeof(DateTime); 528internal static Type typeofDateTimeArray = typeof(DateTime[]);
system\runtime\serialization\formatters\binary\binaryformatterwriter.cs (2)
143internal void WriteDateTime(DateTime value) 765WriteDateTime((DateTime)value);
system\runtime\serialization\formatters\binary\binaryparser.cs (2)
360internal DateTime ReadDateTime() 362return DateTime.FromBinaryRaw(ReadInt64());
system\runtime\serialization\iformatterconverter.cs (1)
39DateTime ToDateTime(Object value);
system\runtime\serialization\serializationinfo.cs (5)
387public void AddValue(String name, DateTime value) 389AddValue(name, (Object)value, typeof(DateTime)); 759public DateTime GetDateTime(String name) 765if (Object.ReferenceEquals(foundType, typeof(DateTime))) 767return (DateTime)value;
system\sbyte.cs (1)
275DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\security\cryptography\x509certificates\x509certificate.cs (11)
69private DateTime m_notBefore; 70private DateTime m_notAfter; 457protected static string FormatDate(DateTime date) { 609m_notBefore = DateTime.MinValue; 610m_notAfter = DateTime.MinValue; 678private DateTime NotAfter { 683if (m_notAfter == DateTime.MinValue) { 686m_notAfter = DateTime.FromFileTime(fileTime.ToTicks()); 692private DateTime NotBefore { 697if (m_notBefore == DateTime.MinValue) { 700m_notBefore = DateTime.FromFileTime(fileTime.ToTicks());
system\single.cs (1)
338DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\string.cs (1)
3430DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\stubhelpers.cs (1)
642static internal extern double ConvertToNative(DateTime managedDate);
system\timezone.cs (16)
90public abstract TimeSpan GetUtcOffset(DateTime time); 95public virtual DateTime ToUniversalTime(DateTime time) { 100if (tickCount>DateTime.MaxTicks) { 101return new DateTime(DateTime.MaxTicks, DateTimeKind.Utc); 103if (tickCount<DateTime.MinTicks) { 104return new DateTime(DateTime.MinTicks, DateTimeKind.Utc); 112public virtual DateTime ToLocalTime(DateTime time) { 126public virtual bool IsDaylightSavingTime(DateTime time) { 132public static bool IsDaylightSavingTime(DateTime time, DaylightTime daylightTimes) { 196internal static TimeSpan CalculateUtcOffset(DateTime time, DaylightTime daylightTimes) { 205DateTime startTime; 206DateTime endTime; 216DateTime ambiguousStart; 217DateTime ambiguousEnd;
system\timezoneinfo.cs (135)
274private static DateTime s_maxDateOnly = new DateTime(9999, 12, 31); 275private static DateTime s_minDateOnly = new DateTime(1, 1, 2); 345DateTime adjustedTime = (TimeZoneInfo.ConvertTime(dateTimeOffset, this)).DateTime; 376public TimeSpan[] GetAmbiguousTimeOffsets(DateTime dateTime) { 382DateTime adjustedTime; 433public TimeSpan GetUtcOffset(DateTime dateTime) { 438internal static TimeSpan GetLocalUtcOffset(DateTime dateTime, TimeZoneInfoOptions flags) { 443internal TimeSpan GetUtcOffset(DateTime dateTime, TimeZoneInfoOptions flags) { 447private TimeSpan GetUtcOffset(DateTime dateTime, TimeZoneInfoOptions flags, CachedData cachedData) { 453DateTime adjustedTime = TimeZoneInfo.ConvertTime(dateTime, cachedData.Local, cachedData.Utc, flags); 504public Boolean IsAmbiguousTime(DateTime dateTime) { 508internal Boolean IsAmbiguousTime(DateTime dateTime, TimeZoneInfoOptions flags) { 513DateTime adjustedTime; 549public Boolean IsDaylightSavingTime(DateTime dateTime) { 553internal Boolean IsDaylightSavingTime(DateTime dateTime, TimeZoneInfoOptions flags) { 557private Boolean IsDaylightSavingTime(DateTime dateTime, TimeZoneInfoOptions flags, CachedData cachedData) { 575DateTime adjustedTime; 620public Boolean IsInvalidTime(DateTime dateTime) { 665static public DateTime ConvertTimeBySystemTimeZoneId(DateTime dateTime, String destinationTimeZoneId) { 671static public DateTime ConvertTimeBySystemTimeZoneId(DateTime dateTime, String sourceTimeZoneId, String destinationTimeZoneId) { 710DateTime utcDateTime = dateTimeOffset.UtcDateTime; 727static public DateTime ConvertTime(DateTime dateTime, TimeZoneInfo destinationTimeZone) { 746static public DateTime ConvertTime(DateTime dateTime, TimeZoneInfo sourceTimeZone, TimeZoneInfo destinationTimeZone) { 751static internal DateTime ConvertTime(DateTime dateTime, TimeZoneInfo sourceTimeZone, TimeZoneInfo destinationTimeZone, TimeZoneInfoOptions flags) { 755static private DateTime ConvertTime(DateTime dateTime, TimeZoneInfo sourceTimeZone, TimeZoneInfo destinationTimeZone, TimeZoneInfoOptions flags, CachedData cachedData) { 811DateTime targetConverted = ConvertUtcToTimeZone(utcTicks, destinationTimeZone, out isAmbiguousLocalDst); 831static public DateTime ConvertTimeFromUtc(DateTime dateTime, TimeZoneInfo destinationTimeZone) { 842static public DateTime ConvertTimeToUtc(DateTime dateTime) { 851static internal DateTime ConvertTimeToUtc(DateTime dateTime, TimeZoneInfoOptions flags) { 859static public DateTime ConvertTimeToUtc(DateTime dateTime, TimeZoneInfo sourceTimeZone) { 1099AdjustmentRule rule = CreateAdjustmentRuleFromTimeZoneInformation(regZone, DateTime.MinValue.Date, DateTime.MaxValue.Date, zone.Bias); 1274private AdjustmentRule GetAdjustmentRuleForTime(DateTime dateTime) { 1283DateTime date = dateTime.Date; 1327static private DateTime ConvertUtcToTimeZone(Int64 ticks, TimeZoneInfo destinationTimeZone, out Boolean isAmbiguousLocalDst) { 1328DateTime utcConverted; 1329DateTime localConverted; 1332if (ticks > DateTime.MaxValue.Ticks) { 1333utcConverted = DateTime.MaxValue; 1335else if (ticks < DateTime.MinValue.Ticks) { 1336utcConverted = DateTime.MinValue; 1346if (ticks > DateTime.MaxValue.Ticks) { 1347localConverted = DateTime.MaxValue; 1349else if (ticks < DateTime.MinValue.Ticks) { 1350localConverted = DateTime.MinValue; 1365static private AdjustmentRule CreateAdjustmentRuleFromTimeZoneInformation(Win32Native.RegistryTimeZoneInformation timeZoneInformation, DateTime startDate, DateTime endDate, int defaultBaseUtcOffset) { 1380TransitionTime.CreateFixedDateRule(DateTime.MinValue, 1, 1), 1381TransitionTime.CreateFixedDateRule(DateTime.MinValue.AddMilliseconds(1), 1, 1), 1467DateTime startTime = TransitionTimeToDateTime(year, rule.DaylightTransitionStart); 1468DateTime endTime = TransitionTimeToDateTime(year, rule.DaylightTransitionEnd); 1478static private Boolean GetIsDaylightSavings(DateTime time, AdjustmentRule rule, DaylightTimeStruct daylightTime, TimeZoneInfoOptions flags) { 1483DateTime startTime; 1484DateTime endTime; 1538static private Boolean GetIsDaylightSavingsFromUtc(DateTime time, Int32 Year, TimeSpan utc, AdjustmentRule rule, out Boolean isAmbiguousLocalDst, TimeZoneInfo zone) { 1561DateTime startTime; 1562if (rule.IsStartDateMarkerForBeginningOfYear() && daylightTime.Start.Year > DateTime.MinValue.Year) { 1575DateTime endTime; 1576if (rule.IsEndDateMarkerForEndOfYear() && daylightTime.End.Year < DateTime.MaxValue.Year) { 1593DateTime ambiguousStart; 1594DateTime ambiguousEnd; 1614DateTime ambiguousStartModified; 1615DateTime ambiguousEndModified; 1639static private Boolean CheckIsDst(DateTime startTime, DateTime time, DateTime endTime,bool ignoreYearAdjustment) { 1681static private Boolean GetIsAmbiguousTime(DateTime time, AdjustmentRule rule, DaylightTimeStruct daylightTime) { 1687DateTime startAmbiguousTime; 1688DateTime endAmbiguousTime; 1712DateTime startModifiedAmbiguousTime; 1713DateTime endModifiedAmbiguousTime; 1745static private Boolean GetIsInvalidTime(DateTime time, AdjustmentRule rule, DaylightTimeStruct daylightTime) { 1751DateTime startInvalidTime; 1752DateTime endInvalidTime; 1778DateTime startModifiedInvalidTime; 1779DateTime endModifiedInvalidTime; 1993static private TimeSpan GetUtcOffset(DateTime time, TimeZoneInfo zone, TimeZoneInfoOptions flags) { 2017static private TimeSpan GetUtcOffsetFromUtc(DateTime time, TimeZoneInfo zone) { 2022static private TimeSpan GetUtcOffsetFromUtc(DateTime time, TimeZoneInfo zone, out Boolean isDaylightSavings) { 2028static internal TimeSpan GetDateTimeNowUtcOffsetFromUtc(DateTime time, out Boolean isAmbiguousLocalDst) { 2052static internal TimeSpan GetUtcOffsetFromUtc(DateTime time, TimeZoneInfo zone, out Boolean isDaylightSavings, out Boolean isAmbiguousLocalDst) { 2060rule = zone.GetAdjustmentRuleForTime(DateTime.MaxValue); 2064rule = zone.GetAdjustmentRuleForTime(DateTime.MinValue); 2068DateTime targetTime = time + baseOffset; 2209static private DateTime TransitionTimeToDateTime(Int32 year, TransitionTime transitionTime) { 2210DateTime value; 2211DateTime timeOfDay = transitionTime.TimeOfDay; 2217Int32 day = DateTime.DaysInMonth(year, transitionTime.Month); 2245Int32 daysInMonth = DateTime.DaysInMonth(year, transitionTime.Month); 2322defaultTimeZoneInformation, DateTime.MinValue.Date, DateTime.MaxValue.Date, defaultBaseUtcOffset); 2362AdjustmentRule rule = CreateAdjustmentRuleFromTimeZoneInformation(dtzi, DateTime.MinValue.Date, DateTime.MaxValue.Date, defaultBaseUtcOffset); 2380DateTime.MinValue.Date, // MinValue 2414DateTime.MaxValue.Date, // MaxValue 3008private DateTime m_dateStart; 3009private DateTime m_dateEnd; 3017public DateTime DateStart { 3023public DateTime DateEnd { 3058this.DaylightTransitionStart.TimeOfDay != DateTime.MinValue || 3059this.DaylightTransitionEnd.TimeOfDay != DateTime.MinValue.AddMilliseconds(1); 3094DateTime dateStart, 3095DateTime dateEnd, 3116DateTime dateStart, 3117DateTime dateEnd, 3156DateTime dateStart, 3157DateTime dateEnd, 3241m_dateStart = (DateTime)info.GetValue("DateStart", typeof(DateTime)); 3242m_dateEnd = (DateTime)info.GetValue("DateEnd", typeof(DateTime)); 3275private DateTime m_timeOfDay; 3284public DateTime TimeOfDay { 3380DateTime timeOfDay, 3389DateTime timeOfDay, 3399DateTime timeOfDay, 3428DateTime timeOfDay, 3501m_timeOfDay = (DateTime)info.GetValue("TimeOfDay", typeof(DateTime)); 3884private DateTime GetNextDateTimeValue(Boolean canEndWithoutSeparator, string format) { 3886DateTime time; 3887if (!DateTime.TryParseExact(token, format, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.None, out time)) { 3987DateTime dateStart = GetNextDateTimeValue(false, dateTimeFormat); 3988DateTime dateEnd = GetNextDateTimeValue(false, dateTimeFormat); 4079DateTime timeOfDay = GetNextDateTimeValue(false, timeOfDayFormat);
system\uint16.cs (1)
242DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\uint32.cs (1)
224DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\uint64.cs (1)
219DateTime IConvertible.ToDateTime(IFormatProvider provider) {
system\variant.cs (4)
107typeof(DateTime), 252public Variant(DateTime val) { 274if (obj is DateTime) { 277ulong ticks = (ulong)((DateTime)obj).Ticks;
PresentationBuildTasks (10)
Base\System\Windows\Markup\TypeConverterHelper.cs (1)
249else if (typeof(DateTime).IsAssignableFrom(type))
BuildTasks\MS\Internal\Tasks\IncrementalCompileAnalyzer.cs (4)
320private DateTime LastCompileTime 324DateTime nonSet = new DateTime(0); 578DateTime dtFile; 610private DateTime _lastCompileTime = new DateTime(0);
BuildTasks\MS\Internal\Tasks\TaskFileService.cs (4)
55DateTime GetLastChangeTime(string srcFile); 218public DateTime GetLastChangeTime(string srcFile) 220DateTime lastChangeDT = new DateTime(0); 230lastChangeDT = DateTime.FromFileTime(fileTime);
Framework\System\Windows\Markup\KnownTypes.cs (1)
5505case KnownElements.DateTime: t = typeof(DateTime); break;
PresentationCore (34)
Core\CSharp\MS\Internal\FontCache\FontSource.cs (2)
183public DateTime GetLastWriteTimeUtc() 208return DateTime.MaxValue;
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\CustomAttributeSerializer.cs (12)
182DateTime [] data = (DateTime[])value; 276DateTime data = (DateTime)value; 672DateTime[] val = new DateTime[count]; 675val[i] = DateTime.FromOADate(br.ReadDouble()); 716return DateTime.FromOADate(br.ReadDouble()); 985DateTime[] data = (DateTime[])value; 992DateTime data = (DateTime)value;
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\SerializationHelper.cs (2)
293else if (typeof(DateTime) == type) 297else if (typeof(DateTime[]) == type)
Core\CSharp\System\Windows\Interop\HwndTarget.cs (9)
230private DateTime _lastWakeOrUnlockEvent; 298_lastWakeOrUnlockEvent = DateTime.MinValue; 1084TimeSpan delta = DateTime.Now - _lastWakeOrUnlockEvent; 1333_lastWakeOrUnlockEvent = DateTime.MinValue; 1349_lastWakeOrUnlockEvent = DateTime.Now; 1372_lastWakeOrUnlockEvent = DateTime.MinValue; 1387_lastWakeOrUnlockEvent = DateTime.Now; 1430_lastWakeOrUnlockEvent = DateTime.Now; 1437_lastWakeOrUnlockEvent = DateTime.MinValue;
Core\CSharp\System\Windows\LayoutManager.cs (5)
284DateTime loopStartTime = new DateTime(0); 294loopStartTime = DateTime.UtcNow; 298TimeSpan loopDuration = (DateTime.UtcNow - loopStartTime); 362loopStartTime = DateTime.UtcNow; 366TimeSpan loopDuration = (DateTime.UtcNow - loopStartTime);
Core\CSharp\System\Windows\Media\Animation\TimeManager.cs (1)
466return TimeSpan.FromTicks(DateTime.Now.Ticks);
Core\CSharp\System\Windows\Media\Imaging\BitmapMetadata.cs (3)
1484DateTime dateTime = DateTime.FromFileTime( (((long)time.dwHighDateTime) << 32) + (uint)time.dwLowDateTime ); 1491DateTime dt = System.Convert.ToDateTime(value, CultureInfo.InvariantCulture);
PresentationFramework (404)
src\Framework\MS\Internal\AppModel\DeploymentExceptionMapper.cs (2)
258DateTime today = System.DateTime.Today;
src\Framework\MS\Internal\Data\DataBindEngine.cs (2)
537long startTime = DateTime.Now.Ticks; // unit = 10^-7 sec 563if (DateTime.Now.Ticks - startTime > CrossThreadThreshold)
src\Framework\MS\Internal\Data\DefaultValueConverter.cs (2)
484if (sourceType == typeof(DateTime)) 486if (targetType == typeof(DateTime))
src\Framework\MS\Internal\Documents\FlowDocumentPaginator.cs (5)
778DateTime dtStart = DateTime.Now; 779DateTime dtStop; 818dtStop = DateTime.Now; 832dtStop = DateTime.Now;
src\Framework\MS\Internal\Documents\TextBoxView.cs (4)
2245DateTime stopTime; 2254stopTime = DateTime.MaxValue; 2258stopTime = DateTime.Now.AddMilliseconds(_maxMeasureTimeMs); 2284while (!endOfParagraph && DateTime.Now < stopTime);
src\Framework\MS\Internal\IO\Packaging\indexingfiltermarshaler.cs (2)
231else if (obj is DateTime) 235long longFileTime = ((DateTime)obj).ToFileTime();
src\Framework\MS\Internal\PtsHost\BackgroundFormatInfo.cs (5)
84_backgroundFormatStopTime = DateTime.UtcNow.AddMilliseconds(_stopTimeDelta); 151internal DateTime BackgroundFormatStopTime { get { return _backgroundFormatStopTime; } } 235private DateTime _backgroundFormatStopTime; 262private DateTime _throttleTimeout = DateTime.UtcNow;
src\Framework\MS\Internal\PtsHost\TextParagraph.cs (1)
310if (backgroundFormatInfo.BackgroundFormatStopTime > DateTime.UtcNow)
src\Framework\MS\Internal\Utility\TraceLog.cs (1)
40string s = DateTime.Now.Ticks.ToString(CultureInfo.InvariantCulture)
src\Framework\System\Windows\Annotations\Annotation.cs (13)
95_created = DateTime.MinValue; 96_modified = DateTime.MinValue; 126_created = DateTime.Now; 146public Annotation(XmlQualifiedName annotationType, Guid id, DateTime creationTime, DateTime lastModificationTime) 466public DateTime CreationTime 478public DateTime LastModificationTime 703if (_created.Equals(DateTime.MinValue)) 707if (_modified.Equals(DateTime.MinValue)) 888_modified = DateTime.Now; 908_modified = DateTime.Now; 952private DateTime _created; 957private DateTime _modified;
src\Framework\System\Windows\Automation\Peers\CalendarAutomationPeer.cs (23)
139DateTime date; 156if (owningButton != null && owningButton.DataContext is DateTime) 158date = (DateTime)owningButton.DataContext; 189DateTime focusedDate; 219private DateTimeAutomationPeer GetOrCreateDateTimeAutomationPeer(DateTime date, CalendarMode buttonMode) 230private DateTimeAutomationPeer GetOrCreateDateTimeAutomationPeer(DateTime date, CalendarMode buttonMode, bool addParentInfo) 310DateTimeAutomationPeer peer = GetOrCreateDateTimeAutomationPeer((DateTime)e.AddedItems[0], CalendarMode.Month); 320foreach (DateTime date in e.AddedItems) 333foreach (DateTime date in e.RemovedItems) 399if (dataContext is DateTime) 401DateTime date = (DateTime)dataContext; 489foreach (DateTime date in OwningCalendar.SelectedDates) 521DateTime? nextDate = null; 533DateTime parsedDate; 534if (DateTime.TryParse((value as string), format, System.Globalization.DateTimeStyles.None, out parsedDate)) 573private DateTime? GetNextDate(DateTimeAutomationPeer currentDatePeer, CalendarMode currentMode) 575DateTime? nextDate = null; 577DateTime startDate = (currentDatePeer != null) ? currentDatePeer.Date : OwningCalendar.DisplayDate; 589private DateTime? GetNextSelectedDate(DateTimeAutomationPeer currentDatePeer, bool isSelected) 591DateTime startDate = (currentDatePeer != null) ? currentDatePeer.Date : OwningCalendar.DisplayDate; 695internal DateTimeCalendarModePair(DateTime date, CalendarMode mode) 702DateTime Date;
src\Framework\System\Windows\Automation\Peers\DateTimeAutomationPeer.cs (2)
31internal DateTimeAutomationPeer(DateTime date, Calendar owningCalendar, CalendarMode buttonMode) 73internal DateTime Date
src\Framework\System\Windows\Controls\Calendar.cs (94)
39private DateTime? _hoverStart; 40private DateTime? _hoverEnd; 42private DateTime? _currentDate; 101this.SetCurrentValueInternal(DisplayDateProperty, DateTime.Today); 190public DateTime DisplayDate 192get { return (DateTime)GetValue(DisplayDateProperty); } 202typeof(DateTime), 204new FrameworkPropertyMetadata(DateTime.MinValue, FrameworkPropertyMetadataOptions.BindsTwoWayByDefault, OnDisplayDateChanged, CoerceDisplayDate)); 216c.DisplayDateInternal = DateTimeHelper.DiscardDayTime((DateTime)e.NewValue); 218c.OnDisplayDateChanged(new CalendarDateChangedEventArgs((DateTime)e.OldValue, (DateTime)e.NewValue)); 225DateTime date = (DateTime)value; 246public DateTime? DisplayDateEnd 248get { return (DateTime?)GetValue(DisplayDateEndProperty); } 258typeof(DateTime?), 280DateTime? date = (DateTime?)value; 289DateTime? maxSelectedDate = c.SelectedDates.MaximumDate; 307public DateTime? DisplayDateStart 309get { return (DateTime?)GetValue(DisplayDateStartProperty); } 319typeof(DateTime?), 342DateTime? date = (DateTime?)value; 346DateTime? minSelectedDate = c.SelectedDates.MinimumDate; 494int i = DateTimeHelper.CompareYearMonth(c.DisplayDateInternal, DateTime.Today); 522public DateTime? SelectedDate 524get { return (DateTime?)GetValue(SelectedDateProperty); } 534typeof(DateTime?), 550DateTime? addedDate; 552addedDate = (DateTime?)e.NewValue; 663internal DateTime DisplayDateInternal 669internal DateTime DisplayDateEndInternal 673return this.DisplayDateEnd.GetValueOrDefault(DateTime.MaxValue); 677internal DateTime DisplayDateStartInternal 681return this.DisplayDateStart.GetValueOrDefault(DateTime.MinValue); 685internal DateTime CurrentDate 691internal DateTime? HoverStart 704internal DateTime? HoverEnd 722internal DateTime DisplayMonth 730internal DateTime DisplayYear 856internal CalendarDayButton FindDayButtonFromDay(DateTime day) 862if (b.DataContext is DateTime) 864if (DateTimeHelper.CompareDays((DateTime)b.DataContext, day) == 0) 877return (value == null) || (!cal.BlackoutDates.Contains((DateTime)value)); 899internal void OnDayClick(DateTime selectedDate) 919if (b.DataContext is DateTime) 921DateTime d = (DateTime)b.DataContext; 923DateTime? newDate = null; 965private DateTime? GetDateOffset(DateTime date, int offset, CalendarMode displayMode) 967DateTime? result = null; 996private void MoveDisplayTo(DateTime? date) 1000DateTime d = date.Value.Date; 1032DateTime? nextDate = GetDateOffset(this.DisplayDate, 1, this.DisplayMode); 1041DateTime? nextDate = GetDateOffset(this.DisplayDate, -1, this.DisplayMode); 1130foreach (DateTime addedDate in e.AddedItems) 1171if (cal.BlackoutDates.Contains((DateTime)value)) 1177return DateTime.Compare((DateTime)value, cal.DisplayDateStartInternal) >= 0 && DateTime.Compare((DateTime)value, cal.DisplayDateEndInternal) <= 0; 1192private void OnSelectedMonthChanged(DateTime? selectedMonth) 1205private void OnSelectedYearChanged(DateTime? selectedYear) 1218internal void FocusDate(DateTime date) 1337DateTime? selectedDate = this._blackoutDates.GetNonBlackoutDate(DateTimeHelper.AddDays(this.CurrentDate, COLS), 1); 1353DateTime? selectedMonth = DateTimeHelper.AddMonths(this.DisplayDate, YEAR_COLS); 1369DateTime? selectedYear = DateTimeHelper.AddYears(this.DisplayDate, YEAR_COLS); 1386DateTime? selectedDate = new DateTime(this.DisplayDateInternal.Year, this.DisplayDateInternal.Month, 1); 1388if (DateTimeHelper.CompareYearMonth(DateTime.MaxValue, selectedDate.Value) > 0) 1396selectedDate = DateTime.MaxValue; 1407DateTime selectedMonth = new DateTime(this.DisplayDate.Year, 12, 1); 1414DateTime? selectedYear = new DateTime(DateTimeHelper.EndOfDecade(this.DisplayDate), 1, 1); 1450DateTime? selectedDate = new DateTime(this.DisplayDateInternal.Year, this.DisplayDateInternal.Month, 1); 1457DateTime selectedMonth = new DateTime(this.DisplayDate.Year, 1, 1); 1464DateTime? selectedYear = new DateTime(DateTimeHelper.DecadeOfDate(this.DisplayDate), 1, 1); 1478DateTime? selectedDate = this._blackoutDates.GetNonBlackoutDate(DateTimeHelper.AddDays(this.CurrentDate, moveAmmount), moveAmmount); 1485DateTime? selectedMonth = DateTimeHelper.AddMonths(this.DisplayDate, moveAmmount); 1492DateTime? selectedYear = DateTimeHelper.AddYears(this.DisplayDate, moveAmmount); 1505DateTime? selectedDate = this._blackoutDates.GetNonBlackoutDate(DateTimeHelper.AddMonths(this.CurrentDate, 1), 1); 1512DateTime? selectedMonth = DateTimeHelper.AddYears(this.DisplayDate, 1); 1519DateTime? selectedYear = DateTimeHelper.AddYears(this.DisplayDate, 10 ); 1532DateTime? selectedDate = this._blackoutDates.GetNonBlackoutDate(DateTimeHelper.AddMonths(this.CurrentDate, -1), -1); 1539DateTime? selectedMonth = DateTimeHelper.AddYears(this.DisplayDate, -1); 1546DateTime? selectedYear = DateTimeHelper.AddYears(this.DisplayDate, -10); 1560DateTime? selectedDate = this._blackoutDates.GetNonBlackoutDate(DateTimeHelper.AddDays(this.CurrentDate, moveAmmount), moveAmmount); 1567DateTime? selectedMonth = DateTimeHelper.AddMonths(this.DisplayDate, moveAmmount); 1574DateTime? selectedYear = DateTimeHelper.AddYears(this.DisplayDate, moveAmmount); 1581private void ProcessSelection(bool shift, DateTime? lastSelectedDate) 1605if (DateTime.Compare(this.HoverStart.Value, lastSelectedDate.Value) < 0) 1673DateTime? selectedDate = this._blackoutDates.GetNonBlackoutDate(DateTimeHelper.AddDays(this.CurrentDate, -COLS), -1); 1689DateTime? selectedMonth = DateTimeHelper.AddMonths(this.DisplayDate, -YEAR_COLS); 1700DateTime? selectedYear = DateTimeHelper.AddYears(this.DisplayDate, -YEAR_COLS);
src\Framework\System\Windows\Controls\CalendarBlackoutDatesCollection.cs (19)
44this.Add(new CalendarDateRange(DateTime.MinValue, DateTime.Today.AddDays(-1))); 52public bool Contains(DateTime date) 63public bool Contains(DateTime start, DateTime end) 65DateTime rangeStart, rangeEnd; 68if (DateTime.Compare(end, start) > -1) 81if (DateTime.Compare(this[i].Start, rangeStart) == 0 && DateTime.Compare(this[i].End, rangeEnd) == 0) 114internal DateTime? GetNonBlackoutDate(DateTime? requestedDate, int dayInterval) 118DateTime? currentDate = requestedDate; 126if ((range = GetContainingDateRange((DateTime)currentDate)) == null) 146} while (currentDate != null && ((range = GetContainingDateRange((DateTime)currentDate)) != null)); 328private bool IsValid(DateTime start, DateTime end) 332DateTime? day = child as DateTime?; 353private CalendarDateRange GetContainingDateRange(DateTime date)
src\Framework\System\Windows\Controls\CalendarDateChangedEventArgs.cs (4)
16internal CalendarDateChangedEventArgs(DateTime? removedDate, DateTime? addedDate) 25public DateTime? AddedDate 34public DateTime? RemovedDate
src\Framework\System\Windows\Controls\CalendarDateRange.cs (16)
18private DateTime _end; 19private DateTime _start; 26this(DateTime.MinValue, DateTime.MaxValue) 34public CalendarDateRange(DateTime day) : 44public CalendarDateRange(DateTime start, DateTime end) 61public DateTime End 70DateTime newEnd = CoerceEnd(_start, value); 83public DateTime Start 94DateTime oldEnd = End; 95DateTime newEnd = CoerceEnd(value, _end); 159private static DateTime CoerceEnd(DateTime start, DateTime end) 161return (DateTime.Compare(start, end) <= 0) ? end : start;
src\Framework\System\Windows\Controls\CalendarDateRangeChangingEventArgs.cs (6)
16public CalendarDateRangeChangingEventArgs(DateTime start, DateTime end) 22public DateTime Start 27public DateTime End 32private DateTime _start; 33private DateTime _end;
src\Framework\System\Windows\Controls\DatePicker.cs (56)
51private DateTime? _originalSelectedDate; 108this.SetCurrentValueInternal(DisplayDateProperty, DateTime.Today); 153public DateTime DisplayDate 155get { return (DateTime)GetValue(DisplayDateProperty); } 165typeof(DateTime), 167new FrameworkPropertyMetadata(DateTime.Now, FrameworkPropertyMetadataOptions.BindsTwoWayByDefault, null, CoerceDisplayDate)); 174dp._calendar.DisplayDate = (DateTime)value; 186public DateTime? DisplayDateEnd 188get { return (DateTime?)GetValue(DisplayDateEndProperty); } 198typeof(DateTime?), 220dp._calendar.DisplayDateEnd = (DateTime?)value; 232public DateTime? DisplayDateStart 234get { return (DateTime?)GetValue(DisplayDateStartProperty); } 244typeof(DateTime?), 267dp._calendar.DisplayDateStart = (DateTime?)value; 403public DateTime? SelectedDate 405get { return (DateTime?)GetValue(SelectedDateProperty); } 415typeof(DateTime?), 429Collection<DateTime> addedItems = new Collection<DateTime>(); 430Collection<DateTime> removedItems = new Collection<DateTime>(); 431DateTime? addedDate; 432DateTime? removedDate; 438addedDate = (DateTime?)e.NewValue; 439removedDate = (DateTime?)e.OldValue; 443DateTime day = dp.SelectedDate.Value; 487dp._calendar.SelectedDate = (DateTime?)value; 534DateTime? date = dp.ParseText(dp._textBox.Text); 538dp.SetTextInternal(dp.DateTimeToString((DateTime)date)); 724_textBox.Text = this.DateTimeToString((DateTime)this.SelectedDate); 960SetCurrentValueInternal(DisplayDateProperty, (DateTime)e.AddedDate); 968if (e.AddedItems.Count > 0 && this.SelectedDate.HasValue && DateTime.Compare((DateTime)e.AddedItems[0], this.SelectedDate.Value) != 0) 970this.SetCurrentValueInternal(SelectedDateProperty, (DateTime?)e.AddedItems[0]); 976this.SetCurrentValueInternal(SelectedDateProperty, (DateTime?)null); 984this.SetCurrentValueInternal(SelectedDateProperty, (DateTime?)e.AddedItems[0]); 990private string DateTimeToString(DateTime d) 1010private static DateTime DiscardDayTime(DateTime d) 1014DateTime newD = new DateTime(year, month, 1, 0, 0, 0); 1018private static DateTime? DiscardTime(DateTime? d) 1026DateTime discarded = (DateTime)d; 1030DateTime newD = new DateTime(year, month, day, 0, 0, 0); 1106private DateTime? ParseText(string text) 1108DateTime newSelectedDate; 1113newSelectedDate = DateTime.Parse(text, DateTimeHelper.GetDateFormat(DateTimeHelper.GetCulture(this))); 1199DateTime? d = SetTextBoxValue(s); 1210this.SetCurrentValueInternal(SelectedDateProperty, (DateTime?)null); 1216DateTime? d = SetTextBoxValue(_defaultText); 1235private DateTime? SetTextBoxValue(string s) 1244DateTime? d = ParseText(s); 1248SafeSetText(this.DateTimeToString((DateTime)d)); 1257string newtext = this.DateTimeToString((DateTime)this.SelectedDate);
src\Framework\System\Windows\Controls\DateTimeHelper.cs (33)
18public static DateTime? AddDays(DateTime time, int days) 30public static DateTime? AddMonths(DateTime time, int months) 42public static DateTime? AddYears(DateTime time, int years) 54public static DateTime? SetYear(DateTime date, int year) 59public static DateTime? SetYearMonth(DateTime date, DateTime yearMonth) 61DateTime? target = SetYear(date, yearMonth.Year); 70public static int CompareDays(DateTime dt1, DateTime dt2) 72return DateTime.Compare(DiscardTime(dt1).Value, DiscardTime(dt2).Value); 75public static int CompareYearMonth(DateTime dt1, DateTime dt2) 80public static int DecadeOfDate(DateTime date) 85public static DateTime DiscardDayTime(DateTime d) 90public static DateTime? DiscardTime(DateTime? d) 100public static int EndOfDecade(DateTime date) 173public static bool InRange(DateTime date, CalendarDateRange range) 179public static bool InRange(DateTime date, DateTime start, DateTime end) 181Debug.Assert(DateTime.Compare(start, end) < 1); 193public static string ToDayString(DateTime? date, CultureInfo culture) 223public static string ToYearMonthPatternString(DateTime? date, CultureInfo culture) 236public static string ToYearString(DateTime? date, CultureInfo culture) 249public static string ToAbbreviatedMonthString( DateTime? date, CultureInfo culture) 266public static string ToLongDateString(DateTime? date, CultureInfo culture)
src\Framework\System\Windows\Controls\Primitives\CalendarItem.cs (53)
137private DateTime DisplayDate 141return (Owner != null) ? Owner.DisplayDate : DateTime.Today; 298DateTime selectedYear; 306selectedYear = DateTime.Today; 379internal CalendarDayButton GetCalendarDayButton(DateTime date) 383if (b != null && b.DataContext is DateTime) 385if (DateTimeHelper.CompareDays(date, (DateTime)b.DataContext) == 0) 395internal CalendarButton GetCalendarButton(DateTime date, CalendarMode mode) 401if (b != null && b.DataContext is DateTime) 405if (DateTimeHelper.CompareYearMonth(date, (DateTime)b.DataContext) == 0) 412if (date.Year == ((DateTime)b.DataContext).Year) 448internal void FocusDate(DateTime date) 484private int GetDecadeForDecadeMode(DateTime selectedYear) 500child.DataContext is DateTime && 501((DateTime)child.DataContext).Year == selectedYear.Year) 511child.DataContext is DateTime && 512((DateTime)child.DataContext).Year == selectedYear.Year) 521private void EndDrag(bool ctrl, DateTime selectedDate) 531DateTime.Compare(this.Owner.HoverStart.Value, selectedDate) == 0 && 571if (!(b.DataContext is DateTime)) 579DateTime clickedDate = (DateTime)b.DataContext; 607DateTime? lastDate = this.Owner.CurrentDate; 665if (this.Owner == null || !(b.DataContext is DateTime)) 684DateTime selectedDate = (DateTime)b.DataContext; 773if (this.Owner == null || !(b.DataContext is DateTime)) 778DateTime selectedDate = (DateTime)b.DataContext; 824if (!(b.DataContext is DateTime)) 829FinishSelection((DateTime)b.DataContext); 833private void FinishSelection(DateTime selectedDate) 1047DateTime firstDayOfMonth = DateTimeHelper.DiscardDayTime(DisplayDate); 1050bool isMinMonth = DateTimeHelper.CompareYearMonth(firstDayOfMonth, DateTime.MinValue) <= 0; 1051bool isMaxMonth = DateTimeHelper.CompareYearMonth(firstDayOfMonth, DateTime.MaxValue) >= 0; 1065DateTime dateToAdd = _calendar.AddDays(firstDayOfMonth, dayOffset); 1079private void SetMonthModeDayButtonState(CalendarDayButton childButton, DateTime? dateToAdd) 1108if (DateTimeHelper.CompareDays(dateToAdd.Value, DateTime.Today) == 0) 1124foreach (DateTime item in this.Owner.SelectedDates) 1154DateTime hStart = owner.HoverEnd.Value; 1155DateTime hEnd = owner.HoverEnd.Value; 1172if (childButton.DataContext is DateTime) 1174DateTime date = (DateTime)childButton.DataContext; 1214DateTime firstDayOfMonth = DateTimeHelper.DiscardDayTime(DisplayDate); 1217if (DateTimeHelper.CompareYearMonth(firstDayOfMonth, DateTime.MaxValue) == 0) 1225DateTime firstDayOfNextMonth = _calendar.AddMonths(firstDayOfMonth, 1); 1235DateTime firstDayOfMonth = DateTimeHelper.DiscardDayTime(DisplayDate); 1254if (year <= DateTime.MaxValue.Year && year >= DateTime.MinValue.Year) 1257DateTime day = new DateTime(year, 1, 1); 1301DateTime day = new DateTime(DisplayDate.Year, count + 1, 1); 1385private int GetNumberOfDisplayedDaysFromPreviousMonth(DateTime firstOfMonth)
src\Framework\System\Windows\Controls\SelectedDatesCollection.cs (50)
20public sealed class SelectedDatesCollection : ObservableCollection<DateTime> 23private Collection<DateTime> _addedItems; 24private Collection<DateTime> _removedItems; 28private DateTime? _maximumDate; 29private DateTime? _minimumDate; 41this._addedItems = new Collection<DateTime>(); 42this._removedItems = new Collection<DateTime>(); 47internal DateTime? MinimumDate 58DateTime result = this[0]; 59foreach (DateTime selectedDate in this) 61if (DateTime.Compare(selectedDate, result) < 0) 74internal DateTime? MaximumDate 85DateTime result = this[0]; 86foreach (DateTime selectedDate in this) 88if (DateTime.Compare(selectedDate, result) > 0) 110public void AddRange(DateTime start, DateTime end) 120foreach (DateTime current in GetDaysInRange(start, end)) 153protected override void InsertItem(int index, DateTime item) 162Collection<DateTime> addedItems = new Collection<DateTime>(); 180if (index == 0 && !(this._owner.SelectedDate.HasValue && DateTime.Compare(this._owner.SelectedDate.Value, item) == 0)) 228Collection<DateTime> addedItems = new Collection<DateTime>(); 229Collection<DateTime> removedItems = new Collection<DateTime>(); 263protected override void SetItem(int index, DateTime item) 272Collection<DateTime> addedItems = new Collection<DateTime>(); 273Collection<DateTime> removedItems = new Collection<DateTime>(); 282if (item != null && DateTime.Compare(this[index], item) != 0 && Calendar.IsValidDateSelection(this._owner, item)) 291if (index == 0 && !(this._owner.SelectedDate.HasValue && DateTime.Compare(this._owner.SelectedDate.Value, item) == 0)) 320internal void AddRangeInternal(DateTime start, DateTime end) 326DateTime lastAddedDate = start; 327foreach (DateTime current in GetDaysInRange(start, end)) 356foreach (DateTime item in this) 373Collection<DateTime> addedItems = new Collection<DateTime>(); 383internal void Toggle(DateTime date) 478private void UpdateMinMax(DateTime date) 497private static IEnumerable<DateTime> GetDaysInRange(DateTime start, DateTime end) 503DateTime? rangeStart = start; 510while (rangeStart.HasValue && DateTime.Compare(end, rangeStart.Value) != -increment); 513private static int GetDirection(DateTime start, DateTime end) 515return (DateTime.Compare(end, start) >= 0) ? 1 : -1;
src\Framework\System\Windows\Controls\VirtualizingStackPanel.cs (3)
12204"Time:", DateTime.Now); 12243"Inactive at", DateTime.Now); 12261"Reactivate at", DateTime.Now);
src\Framework\System\Windows\Data\CollectionView.cs (2)
1876long beginTime = DateTime.Now.Ticks; 1890mustDeferProcessing = DateTime.Now.Ticks - beginTime > DataBindEngine.CrossThreadThreshold;
src\Framework\System\Windows\Documents\Speller.cs (2)
613timeLimit = DateTime.Now.Ticks + MaxIdleTimeSliceNs; 1988long nowTicks = DateTime.Now.Ticks;
src\Framework\System\Windows\Interop\DynamicScriptObject.cs (1)
427if (!Marshal.IsTypeVisibleFromCom(argType) && !argType.IsCOMObject && argType != typeof(DateTime))
src\Framework\System\Windows\Markup\Baml2006\Baml2006KnownTypes.cs (1)
215case 123: t = () => typeof(DateTime); break;
src\Framework\System\Windows\Markup\Baml2006\WpfGeneratedKnownTypes.cs (1)
3193typeof(System.DateTime),
src\Framework\System\Windows\Markup\KnownTypes.cs (1)
5667case KnownElements.DateTime: t = typeof(System.DateTime); break;
SMDiagnostics (1)
System\ServiceModel\Diagnostics\LegacyDiagnosticTrace.cs (1)
131this.LastFailure = DateTime.MinValue;
System (317)
compmod\system\componentmodel\DateTimeConverter.cs (16)
22/// <para>Provides a type converter to convert <see cref='System.DateTime'/> 30/// convert an object in the given source type to a <see cref='System.DateTime'/> 53/// <para>Converts the given value object to a <see cref='System.DateTime'/> 60return DateTime.MinValue; 72return DateTime.Parse(text, formatInfo); 75return DateTime.Parse(text, culture); 87/// <para>Converts the given value object to a <see cref='System.DateTime'/> 92if (destinationType == typeof(string) && value is DateTime) { 93DateTime dt = (DateTime) value; 94if (dt == DateTime.MinValue) { 123if (destinationType == typeof(InstanceDescriptor) && value is DateTime) { 124DateTime dt = (DateTime)value; 129ConstructorInfo ctr = typeof(DateTime).GetConstructor(new Type[] {typeof(Int64)}); 137ConstructorInfo ctor = typeof(DateTime).GetConstructor(new Type[] {
compmod\system\componentmodel\DateTimeOffsetConverter.cs (1)
57/// <para>Converts the given value object to a <see cref='System.DateTime'/>
compmod\system\componentmodel\ReflectTypeDescriptionProvider.cs (1)
135temp[typeof(DateTime)] = typeof(DateTimeConverter);
compmod\system\diagnostics\TraceEventCache.cs (5)
22private DateTime dateTime = DateTime.MinValue; 46public DateTime DateTime { 48if (dateTime == DateTime.MinValue) 49dateTime = DateTime.UtcNow;
compmod\system\diagnostics\XmlWriterTraceListener.cs (1)
205InternalWrite(DateTime.Now.ToString("o", CultureInfo.InvariantCulture));
net\System\Net\_AutoWebProxyScriptHelper.cs (5)
473return weekdayRangeInternal(DateTime.UtcNow, dayOfWeek(wd1), dayOfWeek(_wd2)); 479return weekdayRangeInternal(DateTime.UtcNow, dayOfWeek(wd1), dayOfWeek(wd1)); 481return weekdayRangeInternal(DateTime.Now, dayOfWeek(wd1), dayOfWeek(_wd2)); 483return weekdayRangeInternal(DateTime.Now, dayOfWeek(wd1), dayOfWeek(wd1)); 523private static bool weekdayRangeInternal(DateTime now, DayOfWeek wd1, DayOfWeek wd2)
net\System\Net\_AutoWebProxyScriptWrapper.cs (2)
826internal DateTime LastModified 841private DateTime lastModified;
net\System\Net\_Connection.cs (11)
335private DateTime m_PrepareCloseConnectionSocketCalledUtc; 336private DateTime m_AbortSocketCalledUtc; 337private DateTime m_IdleSinceUtc; 849m_IdleSinceUtc != DateTime.MinValue && 852DateTime.UtcNow) 860((DateTime.UtcNow - m_IdleSinceUtc).TotalSeconds) + 881m_IdleSinceUtc = DateTime.MinValue; 2883m_AbortSocketCalledUtc = DateTime.UtcNow; 2928m_PrepareCloseConnectionSocketCalledUtc = DateTime.UtcNow; 2931m_IdleSinceUtc = DateTime.MinValue; 3879m_IdleSinceUtc = DateTime.UtcNow;
net\System\Net\_FtpControlStream.cs (5)
57private DateTime m_LastModified; 228m_LastModified = DateTime.MinValue; 848internal DateTime LastModified { 900private DateTime GetLastModifiedFrom213Response(string str) { 901DateTime dateTime = m_LastModified;
net\System\Net\_HTTPDateParse.cs (1)
255out DateTime dtOut
net\System\Net\_PooledStream.cs (5)
26private DateTime m_CreateTime; // when the connection was created. 51m_CreateTime = DateTime.UtcNow; 60m_CreateTime = DateTime.UtcNow; 237DateTime utcNow = DateTime.UtcNow;
net\System\Net\Cache\_CacheStreams.cs (6)
848private DateTime m_Expires; 849private DateTime m_LastModified; 850private DateTime m_LastSynchronized; 861DateTime expiresGMT, 862DateTime lastModifiedGMT, 863DateTime lastSynchronizedGMT,
net\System\Net\Cache\_Rfc2616CacheValidators.cs (31)
225if (ctx.CacheDate != DateTime.MinValue && 226ctx.ResponseDate != DateTime.MinValue && 274(ctx.ResponseExpires != DateTime.MinValue && 275(ctx.Policy.MinFresh > TimeSpan.Zero && (ctx.ResponseExpires - DateTime.UtcNow) < ctx.Policy.MinFresh) || 276(ctx.Policy.MaxStale > TimeSpan.Zero && (DateTime.UtcNow - ctx.ResponseExpires) > ctx.Policy.MaxStale))) 374ctx.CacheEntry.LastSynchronizedUtc = DateTime.UtcNow; 501if(Logging.On)Logging.PrintInfo(Logging.RequestCache, SR.GetString(SR.net_log_cache_now_time, DateTime.UtcNow.ToString("r", CultureInfo.InvariantCulture))); 507DateTime nowDate = DateTime.UtcNow; 510DateTime date = ctx.CacheDate; 512if (date != DateTime.MinValue) { 516else if (ctx.CacheEntry.LastSynchronizedUtc != DateTime.MinValue) { 593if (date == DateTime.MinValue) { 597DateTime expiresDate = ctx.CacheEntry.ExpiresUtc; 598if (ctx.CacheExpires != DateTime.MinValue && ctx.CacheExpires < expiresDate) { 603if (expiresDate != DateTime.MinValue && date != DateTime.MinValue && ctx.CacheAge != TimeSpan.MinValue) { 613if (expiresDate != DateTime.MinValue) { 614ctx.CacheMaxAge = expiresDate - DateTime.UtcNow; 617if (expiresDate < DateTime.UtcNow) { 640DateTime lastModifiedDate = ctx.CacheEntry.LastModifiedUtc; 645if (lastModifiedDate != DateTime.MinValue) { 734if (ctx.ResponseDate != DateTime.MinValue && ctx.CacheDate != DateTime.MinValue) { 791if (ctx.ResponseLastModified == DateTime.MinValue && ctx.Response.Headers.ETag == null) { 897if (ctx.Policy.InternalCacheSyncDateUtc != DateTime.MinValue) 1205if (ctx.ResponseLastModified != DateTime.MinValue) { 1208if (ctx.ResponseExpires != DateTime.MinValue) { 1211if (ctx.ResponseDate != DateTime.MinValue) { 1603if (ctx.CacheEntry.LastModifiedUtc != DateTime.MinValue) { 1665if (ctx.CacheEntry.LastModifiedUtc != DateTime.MinValue)
net\System\Net\Cache\_SingleItemRequestCache.cs (12)
138internal override Stream Store(string key, long contentLength, DateTime expiresUtc, DateTime lastModifiedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata) 165internal override void Update(string key, DateTime expiresUtc, DateTime lastModifiedUtc, DateTime lastSynchronizedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata) 204internal override bool TryStore(string key, long contentLength, DateTime expiresUtc, DateTime lastModifiedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata, out Stream writeStream) 214requestCacheEntry.LastAccessedUtc = DateTime.UtcNow; 215requestCacheEntry.LastSynchronizedUtc = DateTime.UtcNow; 263internal override bool TryUpdate(string key, DateTime expiresUtc, DateTime lastModifiedUtc, DateTime lastSynchronizedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata)
net\System\Net\Cache\FtpRequestCacheValidator.cs (12)
32DateTime m_LastModified; 41m_LastModified = DateTime.MinValue; 136DateTime nowDate = DateTime.UtcNow; 141if (CacheEntry.ExpiresUtc != DateTime.MinValue) 153if(CacheEntry.LastSynchronizedUtc != DateTime.MinValue) 162if (CacheEntry.LastModifiedUtc != DateTime.MinValue) 442if (CacheEntry.LastModifiedUtc != DateTime.MinValue && resp.LastModified.ToUniversalTime() != CacheEntry.LastModifiedUtc) 462if (resp.LastModified != DateTime.MinValue) 469CacheEntry.LastSynchronizedUtc = DateTime.UtcNow; 478DateTime nowUtc = DateTime.UtcNow;
net\System\Net\Cache\HttpRequestCacheValidator.cs (19)
65internal DateTime Date; 66internal DateTime Expires; 67internal DateTime LastModified; 77Date = DateTime.MinValue; 78Expires = DateTime.MinValue; 79LastModified = DateTime.MinValue; 119internal DateTime CacheDate {get{return m_CacheVars.Date;} set{m_CacheVars.Date = value;}} 120internal DateTime CacheExpires {get{return m_CacheVars.Expires;} set{m_CacheVars.Expires = value;}} 121internal DateTime CacheLastModified {get{return m_CacheVars.LastModified;} set{m_CacheVars.LastModified = value;}} 129internal DateTime ResponseDate {get{return m_ResponseVars.Date;} set{m_ResponseVars.Date = value;}} 130internal DateTime ResponseExpires {get{return m_ResponseVars.Expires;} set{m_ResponseVars.Expires = value;}} 131internal DateTime ResponseLastModified {get{return m_ResponseVars.LastModified;} set{m_ResponseVars.LastModified = value;}} 515if (ResponseExpires != DateTime.MinValue) { 519if (ResponseLastModified != DateTime.MinValue) 529CacheEntry.LastSynchronizedUtc = DateTime.UtcNow; 735DateTime date = DateTime.MinValue; 749date = DateTime.MinValue; 763date = DateTime.MinValue;
net\System\Net\Cache\IERequestCache.cs (24)
34private readonly static DateTime s_MinDateTimeUtcForFileTimeUtc = DateTime.FromFileTimeUtc(0L); 97internal override Stream Store(string key, long contentLength, DateTime expiresUtc, DateTime lastModifiedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata) 102internal override bool TryStore(string key, long contentLength, DateTime expiresUtc, DateTime lastModifiedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata, out Stream writeStream) 195internal override void Update(string key, DateTime expiresUtc, DateTime lastModifiedUtc, DateTime lastSynchronizedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata) 201internal override bool TryUpdate(string key, DateTime expiresUtc, DateTime lastModifiedUtc, DateTime lastSynchronizedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata) 383private Stream GetWriteStream(string key, long contentLength, DateTime expiresUtc, DateTime lastModifiedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata, bool isThrow) 409if (expiresUtc != DateTime.MinValue && expiresUtc > s_MinDateTimeUtcForFileTimeUtc) { 414if (lastModifiedUtc != DateTime.MinValue && lastModifiedUtc > s_MinDateTimeUtcForFileTimeUtc) { 433Logging.PrintInfo(Logging.RequestCache, SR.GetString(SR.net_log_cache_last_modified, (entry.Info.LastModifiedTime.IsNull? "0": DateTime.FromFileTimeUtc(entry.Info.LastModifiedTime.ToLong()).ToString("r")))); 434Logging.PrintInfo(Logging.RequestCache, SR.GetString(SR.net_log_cache_expires, (entry.Info.ExpireTime.IsNull? "0": DateTime.FromFileTimeUtc(entry.Info.ExpireTime.ToLong()).ToString("r")))); 502private bool UpdateInfo(string key, DateTime expiresUtc, DateTime lastModifiedUtc, DateTime lastSynchronizedUtc, TimeSpan maxStale, StringCollection entryMetadata, StringCollection systemMetadata, bool isThrow) 524if (expiresUtc != DateTime.MinValue && expiresUtc > s_MinDateTimeUtcForFileTimeUtc) { 530if (lastModifiedUtc != DateTime.MinValue && lastModifiedUtc > s_MinDateTimeUtcForFileTimeUtc) { 536if (lastSynchronizedUtc != DateTime.MinValue && lastSynchronizedUtc > s_MinDateTimeUtcForFileTimeUtc) {
net\System\Net\Cache\RequestCache.cs (10)
62DateTime expiresUtc, 63DateTime lastModifiedUtc, 79DateTime expiresUtc, 80DateTime lastModifiedUtc, 81DateTime lastSynchronizedUtc, 95DateTime expiresUtc, 96DateTime lastModifiedUtc, 108DateTime expiresUtc, 109DateTime lastModifiedUtc, 110DateTime lastSynchronizedUtc,
net\System\Net\Cache\RequestCacheEntry.cs (21)
32private DateTime m_ExpiresUtc; 34private DateTime m_LastAccessedUtc; 35private DateTime m_LastModifiedUtc; 36private DateTime m_LastSynchronizedUtc; 47m_ExpiresUtc = m_LastAccessedUtc = m_LastModifiedUtc = m_LastSynchronizedUtc = DateTime.MinValue; 56m_ExpiresUtc = (entry.Info.ExpireTime.IsNull? DateTime.MinValue: DateTime.FromFileTimeUtc(entry.Info.ExpireTime.ToLong())); 58m_LastAccessedUtc= (entry.Info.LastAccessTime.IsNull? DateTime.MinValue: DateTime.FromFileTimeUtc(entry.Info.LastAccessTime.ToLong())); 59m_LastModifiedUtc= (entry.Info.LastModifiedTime.IsNull? DateTime.MinValue: DateTime.FromFileTimeUtc(entry.Info.LastModifiedTime.ToLong())); 60m_LastSynchronizedUtc= (entry.Info.LastSyncTime.IsNull? DateTime.MinValue: DateTime.FromFileTimeUtc(entry.Info.LastSyncTime.ToLong())); 73internal DateTime ExpiresUtc {get{return m_ExpiresUtc;} set{m_ExpiresUtc = value;}} 74internal DateTime LastAccessedUtc {get{return m_LastAccessedUtc;} set{m_LastAccessedUtc = value;}} 75internal DateTime LastModifiedUtc {get{return m_LastModifiedUtc;} set{m_LastModifiedUtc = value;}} 76internal DateTime LastSynchronizedUtc {get{return m_LastSynchronizedUtc;} set{m_LastSynchronizedUtc = value;}} 90sb.Append("\r\nExpires = ").Append(ExpiresUtc == DateTime.MinValue? "": ExpiresUtc.ToString("r", CultureInfo.CurrentCulture)); 91sb.Append("\r\nLastAccessed = ").Append(LastAccessedUtc == DateTime.MinValue? "": LastAccessedUtc.ToString("r", CultureInfo.CurrentCulture)); 92sb.Append("\r\nLastModified = ").Append(LastModifiedUtc == DateTime.MinValue? "": LastModifiedUtc.ToString("r", CultureInfo.CurrentCulture)); 93sb.Append("\r\nLastSynchronized = ").Append(LastSynchronizedUtc == DateTime.MinValue? "": LastSynchronizedUtc.ToString("r", CultureInfo.CurrentCulture));
net\System\Net\Cache\RequestCachePolicy.cs (9)
149private DateTime m_LastSyncDateUtc = DateTime.MinValue; 216public HttpRequestCachePolicy(DateTime cacheSyncDate):this(HttpRequestCacheLevel.Default) 223public HttpRequestCachePolicy(HttpCacheAgeControl cacheAgeControl, TimeSpan maxAge, TimeSpan freshOrStale, DateTime cacheSyncDate) 240public DateTime CacheSyncDate { 242if (m_LastSyncDateUtc == DateTime.MinValue || m_LastSyncDateUtc == DateTime.MaxValue) { 248internal DateTime InternalCacheSyncDateUtc { 278(CacheSyncDate==DateTime.MinValue? string.Empty: " CacheSyncDate:" + CacheSyncDate.ToString(CultureInfo.CurrentCulture));
net\System\Net\cookie.cs (14)
68DateTime m_expires = DateTime.MinValue; 78DateTime m_timeStamp = DateTime.Now; 220return (m_expires != DateTime.MinValue) && (m_expires.ToLocalTime() <= DateTime.Now); 224m_expires = DateTime.Now; 232public DateTime Expires { 644public DateTime TimeStamp { 791if (Expires != DateTime.MinValue) { 792int seconds = (int) (Expires.ToLocalTime() - DateTime.Now).TotalSeconds; 1410DateTime expires; 1411if (DateTime.TryParse(CheckQuoted(m_tokenizer.Value), 1427cookie.Expires = DateTime.Now.AddSeconds((double)parsed);
net\System\Net\cookiecollection.cs (6)
35DateTime m_TimeStamp = DateTime.MinValue; 171internal DateTime TimeStamp(Stamp how) { 174m_TimeStamp = DateTime.Now; 177m_TimeStamp = DateTime.MaxValue; 180m_TimeStamp = DateTime.MinValue;
net\System\Net\cookiecontainer.cs (5)
378DateTime oldUsed = DateTime.MaxValue; 379DateTime tempUsed; 433stamps = Array.CreateInstance(typeof(DateTime), pathList.Count); 480if (oldUsed == DateTime.MaxValue) {
net\System\Net\FtpWebRequest.cs (12)
196private DateTime m_StartTime; 579m_StartTime = DateTime.UtcNow; 588m_RemainingTimeout = Timeout - (int)((DateTime.UtcNow - m_StartTime).TotalMilliseconds); 899m_StartTime = DateTime.UtcNow; 908m_RemainingTimeout = Timeout - (int)((DateTime.UtcNow - m_StartTime).TotalMilliseconds); 1095m_RemainingTimeout = Timeout - (int)((DateTime.UtcNow - m_StartTime).TotalMilliseconds); 1113m_RemainingTimeout = Timeout - (int)((DateTime.UtcNow - m_StartTime).TotalMilliseconds); 1941m_FtpWebResponse = new FtpWebResponse(responseStream, -1, m_Uri, FtpStatusCode.Undefined, null, DateTime.Now, null, null, null); 2082ctx.CacheEntry.LastModifiedUtc == DateTime.MinValue? DateTime.Now: ctx.CacheEntry.LastModifiedUtc.ToLocalTime(), 2149ctx.CacheEntry.LastModifiedUtc == DateTime.MinValue? DateTime.Now: ctx.CacheEntry.LastModifiedUtc.ToLocalTime(),
net\System\Net\FtpWebResponse.cs (3)
30private DateTime m_LastModified; 36internal FtpWebResponse(Stream responseStream, long contentLength, Uri responseUri, FtpStatusCode statusCode, string statusLine, DateTime lastModified, string bannerMessage, string welcomeMessage, string exitMessage) { 204public DateTime LastModified {
net\System\Net\HttpWebRequest.cs (6)
2980private DateTime GetDateHeaderHelper(string headerName) { 2987return DateTime.MinValue; // MinValue means header is not present 2995private void SetDateHeaderHelper(string headerName, DateTime dateTime) { 2999if (dateTime == DateTime.MinValue) 3013public DateTime IfModifiedSince { 3027public DateTime Date {
net\System\Net\HttpWebResponse.cs (2)
280public DateTime LastModified { 287return DateTime.Now;
net\System\Net\Internal.cs (3)
1975internal static DateTime string2date(String S) { 1976DateTime dtOut; 1987internal static string date2string(DateTime D) {
net\System\Net\mail\ContentDisposition.cs (5)
87internal DateTime GetDateParameter(string parameterName) 93return DateTime.MinValue; 162public DateTime CreationDate 178public DateTime ModificationDate 214public DateTime ReadDate
net\System\Net\mail\MailBnfHelper.cs (1)
264internal static string GetDateTimeString(DateTime value, StringBuilder builder)
net\System\Net\mail\Message.cs (1)
433MailBnfHelper.GetDateTimeString(DateTime.Now, null));
net\System\Net\mail\SmtpDateTime.cs (8)
111private readonly DateTime date; 123internal SmtpDateTime(DateTime value) 161internal DateTime Date 167return DateTime.SpecifyKind(this.date, DateTimeKind.Unspecified); 279internal string FormatDate(DateTime value) 290internal DateTime ParseValue(string data, out string timeZone) 323DateTime dateValue; 324if (!DateTime.TryParseExact(date, validDateTimeFormats, CultureInfo.InvariantCulture,
net\System\Net\NetWebProxyFinder.cs (3)
284DateTime lastModified = DateTime.MinValue; 299if (scriptInstance != null && lastModified != DateTime.MinValue && scriptInstance.LastModified == lastModified)
net\System\Net\ServicePoint.cs (9)
54private DateTime m_IdleSince; 136m_IdleSince = DateTime.Now; 162m_IdleSince = DateTime.Now; 524double elapsedDouble = (DateTime.Now - m_IdleSince).TotalMilliseconds; 588public DateTime IdleSince { 1021m_IdleSince = DateTime.Now; 1542private DateTime m_LastDnsResolve; 1579(m_LastDnsResolve + new TimeSpan(0, 0, 0, 0, dnsRefreshTimeout)) < DateTime.UtcNow; 1610m_LastDnsResolve = DateTime.UtcNow;
net\System\Net\webclient.cs (1)
624string boundary = "---------------------" + DateTime.Now.Ticks.ToString("x", NumberFormatInfo.InvariantInfo);
security\system\security\cryptography\x509\x509certificate2.cs (11)
281private DateTime m_notBefore; 282private DateTime m_notAfter; 704public DateTime NotAfter { 712if (m_notAfter == DateTime.MinValue) { 717m_notAfter = DateTime.FromFileTime(dt); 725public DateTime NotBefore { 733if (m_notBefore == DateTime.MinValue) { 738m_notBefore = DateTime.FromFileTime(dt); 1115m_notBefore = DateTime.MinValue; 1116m_notAfter = DateTime.MinValue; 1141DateTime.Now,
security\system\security\cryptography\x509\x509certificate2collection.cs (7)
477if (findValue.GetType() != typeof(DateTime)) 479*((long*) &ft) = ((DateTime) findValue).ToFileTime(); 485if (findValue.GetType() != typeof(DateTime)) 487*((long*) &ft) = ((DateTime) findValue).ToFileTime(); 493if (findValue.GetType() != typeof(DateTime)) 495*((long*) &ft) = ((DateTime) findValue).ToFileTime(); 659DateTime.Now,
security\system\security\cryptography\x509\x509chain.cs (1)
349DateTime verificationTime,
security\system\security\cryptography\x509\x509chainpolicy.cs (3)
49private DateTime m_verificationTime; 103public DateTime VerificationTime { 133m_verificationTime = DateTime.Now;
security\system\security\cryptography\x509\x509utils.cs (1)
548DateTime verificationTime,
services\monitoring\system\diagnosticts\EventLogEntry.cs (3)
334public DateTime TimeGenerated { 348public DateTime TimeWritten { 610private static readonly DateTime beginningOfTime = new DateTime(1970, 1, 1, 0, 0, 0);
services\monitoring\system\diagnosticts\Process.cs (7)
86DateTime exitTime; 331public DateTime ExitTime { 998public DateTime StartTime { 2802public DateTime StartTime { 2804return DateTime.FromFileTime(create); 2808public DateTime ExitTime { 2810return DateTime.FromFileTime(exit);
services\monitoring\system\diagnosticts\ProcessThread.cs (1)
238public DateTime StartTime {
services\monitoring\system\diagnosticts\SharedPerformanceCounter.cs (2)
932long tickDelta = (DateTime.Now.Ticks - Volatile.Read(ref LastInstanceLifetimeSweepTick)); 1026Volatile.Write(ref LastInstanceLifetimeSweepTick, DateTime.Now.Ticks);
services\monitoring\system\diagnosticts\Stopwatch.cs (1)
142return DateTime.UtcNow.Ticks;
services\timers\system\timers\ElapsedEventArgs.cs (3)
13private DateTime signalTime; 17this.signalTime = DateTime.FromFileTime(fileTime); 20public DateTime SignalTime {
sys\system\configuration\SettingsPropertyValue.cs (1)
46if (_Value != null && !Property.PropertyType.IsPrimitive && !(_Value is string) && !(_Value is DateTime))
System.Activities (24)
System\Activities\Debugger\DebugInfo.cs (1)
410else if (t == typeof(DateTime))
System\Activities\Expressions\Literal.cs (5)
91if (valueType == typeof(DateTime)) 93DateTime literalValue = (DateTime)(object)this.Value; 109static bool IsShortTimeFormattingSafe(DateTime literalValue) 117DateTime noLeftOverTicksDateTime = new DateTime(
System\Activities\Statements\TimerTable.cs (10)
52DateTime dueTime = TimeoutHelper.Add(DateTime.UtcNow, timeout); 128public DateTime GetNextDueTime() 136return DateTime.MaxValue; 148if (timerData.ExpirationTime <= DateTime.UtcNow) 155timerData.IOThreadTimer.Set(timerData.ExpirationTime - DateTime.UtcNow); 210DateTime expirationTime; 212public TimerData(Bookmark timerBookmark, DateTime expirationTime) 230public DateTime ExpirationTime 256internal DateTime SerializedExpirationTime
System\Activities\Tracking\EtwTrackingParticipant.cs (3)
188else if (valueType == typeof(DateTime)) 190DateTime date = ((DateTime)item.Value).ToUniversalTime();
System\Activities\Tracking\TrackingRecord.cs (4)
21DateTime eventTime; 30this.EventTime = DateTime.UtcNow; 69public DateTime EventTime 118internal DateTime SerializedEventTime
System\Activities\WorkflowApplication.cs (1)
5843data[WorkflowNamespace.LastUpdate] = new InstanceValue(DateTime.UtcNow, InstanceValueOptions.WriteOnly | InstanceValueOptions.Optional);
System.Activities.Core.Presentation (1)
System\ServiceModel\Activities\Presentation\ContentCorrelationTypeExpander.xaml.cs (1)
58typeof(DateTime),
System.Activities.DurableInstancing (24)
System\Activities\DurableInstancing\DetectRunnableInstancesAsyncResult.cs (2)
74DateTime expirationTime = reader.GetDateTime(1); 75DateTime utcNow = reader.GetDateTime(2);
System\Activities\DurableInstancing\LoadRetryExponentialBackoffStrategy.cs (1)
17Random random = new Random(DateTime.Now.Millisecond);
System\Activities\DurableInstancing\LoadRetryHandler.cs (14)
14BinaryHeap<DateTime, LoadRetryAsyncResult> retryQueue; 20this.retryQueue = new BinaryHeap<DateTime, LoadRetryAsyncResult>(); 28DateTime retryTime = DateTime.UtcNow.Add(command.RetryTimeout); 47ICollection<KeyValuePair<DateTime, LoadRetryAsyncResult>> result; 54foreach (KeyValuePair<DateTime, LoadRetryAsyncResult> value in result) 71ICollection<KeyValuePair<DateTime, LoadRetryAsyncResult>> retryList; 78DateTime currentTime = DateTime.UtcNow; 79DateTime expirationTime = retryQueue.Peek().Key; 96DateTime currentTime = DateTime.UtcNow; 101DateTime expirationTime = this.retryQueue.Peek().Key; 106foreach (KeyValuePair<DateTime, LoadRetryAsyncResult> retry in retryList)
System\Activities\DurableInstancing\SaveWorkflowAsyncResult.cs (3)
249DateTime pendingTimerExpiration = ((DateTime)pendingTimerExpirationPropertyValue.Value).ToUniversalTime(); 250TimeSpan datetimeOffset = pendingTimerExpiration - DateTime.UtcNow;
System\Activities\DurableInstancing\SerializationUtilities.cs (1)
75(value.Value is DateTime) ||
System\Activities\DurableInstancing\XmlPropertyBag.cs (3)
87else if (value is DateTime) 236else if (value is DateTime) 238return XmlConvert.ToString((DateTime)value, XmlDateTimeSerializationMode.RoundtripKind);
System.Activities.Presentation (11)
System.Activities.Presentation\System\Activities\Presentation\DesignObjectWrapper.cs (4)
69DateTime timestamp; 536PropertyType = typeof(DateTime), 557this.timestamp = DateTime.Now; 561protected DateTime GetTimestamp()
System.Activities.Presentation\System\Activities\Presentation\ExpressionHelper.cs (1)
143return type.IsPrimitive || type == typeof(string) || type == typeof(TimeSpan) || type == typeof(DateTime);
System.Activities.Presentation\System\Activities\Presentation\View\DesignerView.Commands.cs (1)
522System.Diagnostics.Debug.WriteLine(string.Format(CultureInfo.InvariantCulture, "{0} DesignerView.OnWorkflowViewContextMenuLoaded()", DateTime.Now.ToLocalTime()));
System.Activities.Presentation\System\Activities\Presentation\View\DesignerView.xaml.cs (1)
653DateTime.Now.ToLocalTime(), (null == this.FocusedViewElement ? "<null>" : this.FocusedViewElement.GetType().Name), e.OriginalSource));
System.Activities.Presentation\System\Activities\Presentation\WorkflowViewElement.cs (4)
547DateTime.Now.ToLocalTime(), this.GetType().Name, selection.SelectionCount, becomesSelection, e.OriginalSource)); 642DateTime.Now.ToLocalTime(), this.GetType().Name, shouldSetFocus, this.IsMouseCaptured, e.OriginalSource)); 650DateTime.Now.ToLocalTime(), this.GetType().Name)); 814DateTime.Now.ToLocalTime(), this.GetType().Name, this.IsMouseCaptured));
System.AddIn (11)
System\Addin\Hosting\AddInStore.cs (11)
66internal DateTime FileTimeStamp; // Creation time of the file, when we read it. 261DateTime storeTime = File.GetLastWriteTime(deploymentStore); 304DateTime storeTime = File.GetLastWriteTime(storeName); 328private static bool DirectoryNeedsUpdating(string path, DateTime storeTime, ref int fileCount) 773DateTime lastWriteTime = File.GetCreationTime(fileName); 781DateTime timeStamp = File.GetCreationTime(fileName); 830DateTime timeStamp = DateTime.Now; 908DateTime timeStamp = DateTime.Now; 1010private static void WriteCache(DeploymentState state, String path, String fileName, DateTime timeStamp)
System.AddIn.Contract (7)
System\Addin\Contract\RemoteArgument.cs (7)
179DateTime dateTimeToUse; 183dateTimeToUse = (DateTime)convertibleValue; 433public RemoteArgument(System.DateTime value) 441public RemoteArgument(System.DateTime value, bool isByRef) 937public System.DateTime DateTimeValue 945return default(System.DateTime); 951return (System.DateTime)this._value;
System.Configuration (11)
System\Configuration\Internal\FileVersion.cs (4)
23DateTime _utcCreationTime; 24DateTime _utcLastWriteTime; 26internal FileVersion(bool exists, long fileSize, DateTime utcCreationTime, DateTime utcLastWriteTime) {
System\Configuration\Internal\InternalConfigHost.cs (6)
114DateTime utcCreationTime = DateTime.MinValue; 115DateTime utcLastWriteTime = DateTime.MinValue; 122utcCreationTime = DateTime.FromFileTimeUtc(((long)data.ftCreationTimeHigh) << 32 | (long)data.ftCreationTimeLow); 123utcLastWriteTime = DateTime.FromFileTimeUtc(((long)data.ftLastWriteTimeHigh) << 32 | (long)data.ftLastWriteTimeLow);
System\Configuration\Internal\WriteFileContext.cs (1)
107DateTime creationTime;
System.Core (44)
Microsoft\Scripting\Ast\ParameterExpression.cs (1)
52case TypeCode.DateTime: return new PrimitiveParameterExpression<DateTime>(name);
System\Diagnostics\Eventing\Reader\EventLogInformation.cs (9)
30DateTime? creationTime; 31DateTime? lastAccessTime; 32DateTime? lastWriteTime; 47creationTime = (DateTime?)NativeWrapper.EvtGetLogInfo(logHandle, UnsafeNativeMethods.EvtLogPropertyId.EvtLogCreationTime); 48lastAccessTime = (DateTime?)NativeWrapper.EvtGetLogInfo(logHandle, UnsafeNativeMethods.EvtLogPropertyId.EvtLogLastAccessTime); 49lastWriteTime = (DateTime?)NativeWrapper.EvtGetLogInfo(logHandle, UnsafeNativeMethods.EvtLogPropertyId.EvtLogLastWriteTime); 58public DateTime? CreationTime { get { return creationTime; } } 59public DateTime? LastAccessTime { get { return lastAccessTime; } } 60public DateTime? LastWriteTime { get { return lastWriteTime; } }
System\Diagnostics\Eventing\Reader\EventLogRecord.cs (1)
202public override DateTime? TimeCreated {
System\Diagnostics\Eventing\Reader\EventRecord.cs (1)
47public abstract DateTime? TimeCreated { get; }
System\Diagnostics\Eventing\Reader\NativeWrapper.cs (10)
54public DateTime? TimeCreated = null; 874systemProperties.TimeCreated = (DateTime?)ConvertToObject(varVal, UnsafeNativeMethods.EvtVariantType.EvtVarTypeFileTime); 1199return DateTime.FromFileTime((long)val.FileTime); 1344return new DateTime[0]; 1347DateTime[] array = new DateTime[val.Count]; 1349array[i] = DateTime.FromFileTime(Marshal.ReadInt64(ptr)); 1360return new DateTime[0]; 1363DateTime[] array = new DateTime[val.Count];
System\Diagnostics\Eventing\Reader\ProviderMetadataCachedInformation.cs (6)
75private DateTime theTime; 79theTime = DateTime.Now; 82public DateTime TheTime { 136DateTime timeNow = DateTime.Now; 156cacheItem.TheTime = DateTime.Now;
System\Diagnostics\EventSchemaTraceListener.cs (1)
309_InternalBuildRaw(writer, DateTime.UtcNow.ToString("o", CultureInfo.InvariantCulture));
System\Linq\Parallel\Merging\AsynchronousChannelMergeEnumerator.cs (1)
269TraceHelpers.TraceInfo("[timing]: {0}: Completed the merge", DateTime.Now.Ticks);
System\Linq\Parallel\Merging\SynchronousChannelMergeEnumerator.cs (1)
112TraceHelpers.TraceInfo("[timing]: {0}: Completed the merge", DateTime.Now.Ticks);
System\Linq\Parallel\QueryOperators\PartitionedStreamMerger.cs (1)
67TraceHelpers.TraceInfo("[timing]: {0}: finished opening - QueryOperator<>::GetEnumerator", DateTime.Now.Ticks);
System\Linq\Parallel\QueryOperators\QueryOperator.cs (1)
183TraceHelpers.TraceInfo("[timing]: {0}: starting execution - QueryOperator<>::GetQueryResults", DateTime.Now.Ticks);
System\Linq\Parallel\Scheduling\QueryTask.cs (4)
67TraceHelpers.TraceInfo("[timing]: {0}: Running work synchronously", DateTime.Now.Ticks, m_taskIndex); 86TraceHelpers.TraceInfo("[timing]: {0}: Queue work {1} to occur asynchronously", DateTime.Now.Ticks, m_taskIndex); 98TraceHelpers.TraceInfo("[timing]: {0}: Start work {1}", DateTime.Now.Ticks, m_taskIndex); 117TraceHelpers.TraceInfo("[timing]: {0}: End work {1}", DateTime.Now.Ticks, m_taskIndex);
System\Linq\Parallel\Utils\Util.cs (4)
61else if (typeof(TKey) == typeof(DateTime)) 111class FastDateTimeComparer : Comparer<DateTime> 113public override int Compare(DateTime x, DateTime y)
System\Security\Cryptography\X509Certificates\TimestampInformation.cs (3)
19private DateTime m_timestamp; 32m_timestamp = DateTime.FromFileTimeUtc((long)filetime); 96public DateTime Timestamp {
System.Data (287)
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\DesignObjectWrapper.cs (4)
69DateTime timestamp; 536PropertyType = typeof(DateTime), 557this.timestamp = DateTime.Now; 561protected DateTime GetTimestamp()
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\ExpressionHelper.cs (1)
143return type.IsPrimitive || type == typeof(string) || type == typeof(TimeSpan) || type == typeof(DateTime);
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\View\DesignerView.Commands.cs (1)
522System.Diagnostics.Debug.WriteLine(string.Format(CultureInfo.InvariantCulture, "{0} DesignerView.OnWorkflowViewContextMenuLoaded()", DateTime.Now.ToLocalTime()));
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\View\DesignerView.xaml.cs (1)
653DateTime.Now.ToLocalTime(), (null == this.FocusedViewElement ? "<null>" : this.FocusedViewElement.GetType().Name), e.OriginalSource));
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\WorkflowViewElement.cs (4)
547DateTime.Now.ToLocalTime(), this.GetType().Name, selection.SelectionCount, becomesSelection, e.OriginalSource)); 642DateTime.Now.ToLocalTime(), this.GetType().Name, shouldSetFocus, this.IsMouseCaptured, e.OriginalSource)); 650DateTime.Now.ToLocalTime(), this.GetType().Name)); 814DateTime.Now.ToLocalTime(), this.GetType().Name, this.IsMouseCaptured));
fx\src\data\Microsoft\SqlServer\Server\ITypedGetters.cs (1)
49DateTime GetDateTime( int ordinal );
fx\src\data\Microsoft\SqlServer\Server\ITypedGettersV3.cs (1)
67DateTime GetDateTime( SmiEventSink sink, int ordinal );
fx\src\data\Microsoft\SqlServer\Server\ITypedSetters.cs (1)
48void SetDateTime( int ordinal, DateTime value );
fx\src\data\Microsoft\SqlServer\Server\ITypedSettersV3.cs (1)
76void SetDateTime( SmiEventSink sink, int ordinal, DateTime value );
fx\src\data\Microsoft\SqlServer\Server\MemoryRecordBuffer.cs (2)
105public override DateTime GetDateTime(SmiEventSink sink, int ordinal) { 202public override void SetDateTime(SmiEventSink sink, int ordinal, DateTime value) {
fx\src\data\Microsoft\SqlServer\Server\MetadataUtilsSmi.cs (2)
96ht.Add( typeof( System.DateTime ), ExtendedClrTypeCode.DateTime ); 263if (value.GetType() == typeof( DateTime ))
fx\src\data\Microsoft\SqlServer\Server\SmiMetaData.cs (2)
78internal static readonly DateTime MaxSmallDateTime = new DateTime(2079, 06, 06, 23, 59, 29, 998); 79internal static readonly DateTime MinSmallDateTime = new DateTime(1899, 12, 31, 23, 59, 29, 999);
fx\src\data\Microsoft\SqlServer\Server\SmiRecordBuffer.cs (2)
232public virtual DateTime GetDateTime( int ordinal ) { 585public virtual void SetDateTime( int ordinal, DateTime value ) {
fx\src\data\Microsoft\SqlServer\Server\SmiRequestExecutor.cs (2)
290public virtual DateTime GetDateTime( int ordinal ) { 643public virtual void SetDateTime( int ordinal, DateTime value ) {
fx\src\data\Microsoft\SqlServer\Server\SmiTypedGetterSetter.cs (2)
181public virtual DateTime GetDateTime(SmiEventSink sink, int ordinal) { 381public virtual void SetDateTime(SmiEventSink sink, int ordinal, DateTime value) {
fx\src\data\Microsoft\SqlServer\Server\SqlDataRecord.cs (2)
209public virtual DateTime GetDateTime(int ordinal) { 468public virtual void SetDateTime(int ordinal, DateTime value) {
fx\src\data\Microsoft\SqlServer\Server\SqlRecordBuffer.cs (2)
43[FieldOffset(0)] internal DateTime _dateTime; 99internal DateTime DateTime {
fx\src\data\Microsoft\SqlServer\Server\ValueUtilsSmi.cs (19)
189internal static DateTime GetDateTime( SmiEventSink_Default sink, ITypedGettersV3 getters, int ordinal, SmiMetaData metaData ) { 198return (DateTime) result; 442DateTime temp = GetDateTime_Unchecked( sink, getters, ordinal ); 1402internal static void SetDateTime( SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData, DateTime value ) { 1598case ExtendedClrTypeCode.DateTime: SetDateTime_Checked( sink, setters, ordinal, metaData, (DateTime)value ); break; 1665SetDateTime2_Checked(sink, setters, ordinal, metaData, (DateTime)value); 1667SetDate_Checked(sink, setters, ordinal, metaData, (DateTime)value); 1669SetDateTime_Checked(sink, setters, ordinal, metaData, (DateTime)value); 2418private static readonly DateTime x_dtSmallMax = new DateTime(2079, 06, 06, 23, 59, 29, 998); 2419private static readonly DateTime x_dtSmallMin = new DateTime(1899, 12, 31, 23, 59, 29, 999); 2420private static void VerifyDateTimeRange(SqlDbType dbType, DateTime value) { 2434private static void SetDateTime_Checked(SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData, DateTime value) { 2451private static void SetDateTime2_Checked(SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData, DateTime value) 2457private static void SetDate_Checked(SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData, DateTime value) 3082private static DateTime GetDateTime_Unchecked( SmiEventSink_Default sink, ITypedGettersV3 getters, int ordinal ) { 3085DateTime result = getters.GetDateTime( sink, ordinal ); 3316private static void SetDateTime_Unchecked( SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, DateTime value ) { 3321private static void SetDateTime2_Unchecked(SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData, DateTime value) 3329private static void SetDate_Unchecked(SmiEventSink_Default sink, ITypedSettersV3 setters, int ordinal, SmiMetaData metaData, DateTime value)
fx\src\data\System\Data\CodeGen\datacache.cs (1)
863}else if(col.DataType == typeof(DateTime) || col.DataType == typeof(TimeSpan)) {
fx\src\data\System\Data\ColumnTypeConverter.cs (1)
29typeof(DateTime),
fx\src\data\System\Data\Common\AdapterUtil.cs (2)
1926ticks = DateTime.UtcNow.ToFileTimeUtc(); 1930return DateTime.UtcNow.ToFileTimeUtc();
fx\src\data\System\Data\Common\DataRecordInternal.cs (2)
273public override DateTime GetDateTime(int i) { 274return((DateTime) _values[i]);
fx\src\data\System\Data\Common\DataStorage.cs (1)
87typeof(DateTime),
fx\src\data\System\Data\Common\DateTimeStorage.cs (32)
18private static readonly DateTime defaultValue = DateTime.MinValue; 20private DateTime[] values; 23: base(column, typeof(DateTime), defaultValue, StorageType.DateTime) { 31DateTime min = DateTime.MaxValue; 35min=(DateTime.Compare(values[record],min) < 0) ? values[record] : min; 45DateTime max = DateTime.MinValue; 49max=(DateTime.Compare(values[record],max) >= 0) ? values[record] : max; 75throw ExprException.Overflow(typeof(DateTime)); 81DateTime valueNo1 = values[recordNo1]; 82DateTime valueNo2 = values[recordNo2]; 90return DateTime.Compare(valueNo1, valueNo2); 101DateTime valueNo1 = values[recordNo]; 105return DateTime.Compare(valueNo1, (DateTime)value); 127DateTime value = values[record]; 141DateTime retVal; 142DateTime tmpValue = ((IConvertible)value).ToDateTime(FormatProvider); 152retVal = DateTime.SpecifyKind(tmpValue, DateTimeKind.Utc); 163retVal = DateTime.SpecifyKind(tmpValue, DateTimeKind.Local); 168retVal = DateTime.SpecifyKind(tmpValue, DateTimeKind.Unspecified); 179DateTime[] newValues = new DateTime[capacity]; 201retValue = XmlConvert.ToString((DateTime)value, XmlDateTimeSerializationMode.Local); 204retValue = XmlConvert.ToString((DateTime)value, XmlDateTimeSerializationMode.RoundtripKind); 210return new DateTime[recordCount]; 214DateTime[] typedStore = (DateTime[]) store; 226values = (DateTime[]) store; 231values[i] = DateTime.SpecifyKind(values[i].ToLocalTime(), DateTimeKind.Unspecified); //Strip the kind for UnspecifiedLocal.
fx\src\data\System\Data\Common\DbDataReader.cs (1)
122abstract public DateTime GetDateTime(int ordinal);
fx\src\data\System\Data\Common\dbdatarecord.cs (1)
53public abstract DateTime GetDateTime(int i);
fx\src\data\System\Data\Common\ObjectStorage.cs (8)
430if (!isNull && (typedStore[storeIndex] is DateTime)) { 431DateTime dt = (DateTime)typedStore[storeIndex]; 433typedStore[storeIndex] = DateTime.SpecifyKind(dt.ToUniversalTime(), DateTimeKind.Local); 441if (values[i] is DateTime) { 442DateTime dt = (DateTime) values[i]; 444values[i] = (DateTime.SpecifyKind(dt, DateTimeKind.Utc)).ToLocalTime();
fx\src\data\System\Data\Common\SQLConvert.cs (3)
305return (DateTime) value; 522return ((IConvertible)(DateTime)value).ToString(formatProvider); 769return XmlConvert.ToString((DateTime)value, XmlDateTimeSerializationMode.RoundtripKind);
fx\src\data\System\Data\DataColumn.cs (1)
631if (DataType != typeof(DateTime) && value != DataSetDateTime.UnspecifiedLocal) { //Check for column being DateTime. If the column is not DateTime make sure the value that is being is only the default[UnspecifiedLocal].
fx\src\data\System\Data\DataRelation.cs (1)
642((parentKey.ColumnsReference[i].DataType == typeof(DateTime)) &&
fx\src\data\System\Data\DataTableReader.cs (2)
414override public DateTime GetDateTime (int ordinal) { 418return (DateTime) currentDataRow[ordinal];
fx\src\data\System\Data\Filter\BinaryNode.cs (13)
158return DateTime.Compare(Convert.ToDateTime(vLeft, FormatProvider), Convert.ToDateTime(vRight, FormatProvider)); 337if (vLeft is TimeSpan && vRight is DateTime) { 338value = (DateTime)vRight + (TimeSpan)vLeft; 340else if (vLeft is DateTime && vRight is TimeSpan) { 341value = (DateTime)vLeft + (TimeSpan)vRight; 380value = (SqlDateTime)SqlConvert.ConvertToSqlDateTime((DateTime)rValue.Value + (TimeSpan)vLeft); 384value = (SqlDateTime)SqlConvert.ConvertToSqlDateTime((DateTime)lValue.Value + (TimeSpan)vRight); 456value = (DateTime)vLeft - (TimeSpan)vRight; 459if (vLeft is DateTime) { 460value = (DateTime)vLeft - (DateTime)vRight; 468value = (SqlDateTime)SqlConvert.ConvertToSqlDateTime((DateTime)rValue.Value - (TimeSpan)vLeft); 472value = (SqlDateTime)SqlConvert.ConvertToSqlDateTime((DateTime)lValue.Value - (TimeSpan)vRight);
fx\src\data\System\Data\Filter\ConstNode.cs (1)
54this.val = DateTime.Parse((string)constant, CultureInfo.InvariantCulture);
fx\src\data\System\Data\Filter\FunctionNode.cs (3)
37new Function("DateTimeOffset", FunctionId.DateTimeOffset, typeof(DateTimeOffset), false, true, 3, typeof(DateTime), typeof(int), typeof(int)), 457switch (((DateTime)argumentValues[0]).Kind) { 480return new DateTimeOffset((DateTime)argumentValues[0], new TimeSpan((int)argumentValues[1], (int)argumentValues[2], 0));
fx\src\data\System\Data\ForeignKeyConstraint.cs (1)
561((parentKey.ColumnsReference[i].DataType == typeof(DateTime)) && (parentKey.ColumnsReference[i].DateTimeMode != childKey.ColumnsReference[i].DateTimeMode) && ((parentKey.ColumnsReference[i].DateTimeMode & childKey.ColumnsReference[i].DateTimeMode) != DataSetDateTime.Unspecified)))
fx\src\data\System\Data\IDataRecord.cs (1)
60DateTime GetDateTime(int i);
fx\src\data\System\Data\Merger.cs (1)
318((dest.DataType == typeof(DateTime)) && (dest.DateTimeMode != src.DateTimeMode) && ((dest.DateTimeMode & src.DateTimeMode) != DataSetDateTime.Unspecified))) {
fx\src\data\System\Data\Odbc\Odbc32.cs (3)
780static private readonly TypeMap _DateTime = new TypeMap(OdbcType.DateTime, DbType.DateTime, typeof(DateTime), ODBC32.SQL_TYPE.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, 16, 23, false); 781static private readonly TypeMap _Date = new TypeMap(OdbcType.Date, DbType.Date, typeof(DateTime), ODBC32.SQL_TYPE.TYPE_DATE, ODBC32.SQL_C.TYPE_DATE, ODBC32.SQL_C.TYPE_DATE, 6, 10, false); 794static private readonly TypeMap _SmallDT = new TypeMap(OdbcType.SmallDateTime, DbType.DateTime, typeof(DateTime), ODBC32.SQL_TYPE.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, ODBC32.SQL_C.TYPE_TIMESTAMP, 16, 23, false);
fx\src\data\System\Data\Odbc\OdbcDataReader.cs (4)
701public DateTime GetDate(int i) { 702return (DateTime)internalGetDate(i); 717override public DateTime GetDateTime(int i) { 718return (DateTime)internalGetDateTime(i);
fx\src\data\System\Data\Odbc\OdbcUtils.cs (3)
271WriteODBCDateTime(offset, (DateTime)value); 285WriteDate(offset, (DateTime)value); 327internal void WriteODBCDateTime(int offset, DateTime value) {
fx\src\data\System\Data\OleDb\ColumnBinding.cs (17)
429Value_DATE((DateTime) value); 491Value_FILETIME((DateTime) value); 511Value_DBDATE((DateTime) value); 517Value_DBTIMESTAMP((DateTime) value); 727private DateTime Value_DATE() { 730return DateTime.FromOADate(RowBinding.ReadDouble(ValueOffset)); 732private void Value_DATE(DateTime value) { 739private DateTime Value_DBDATE() { 744private void Value_DBDATE(DateTime value) { 763private DateTime Value_DBTIMESTAMP() { 768private void Value_DBTIMESTAMP(DateTime value) { 818private DateTime Value_FILETIME() { 822return DateTime.FromFileTime(tmp); 824private void Value_FILETIME(DateTime value) { 1198internal DateTime ValueDateTime() { 1199DateTime value; 1216value = (DateTime) ValueVariant();
fx\src\data\System\Data\OleDb\OLEDB_Enum.cs (4)
163static private readonly NativeDBType D_Date = new NativeDBType(0xff, 8, true, false, OleDbType.Date, NativeDBType.DATE, S_DATE, typeof(System.DateTime), NativeDBType.DATE, DbType.DateTime ); // 5 - double 164static private readonly NativeDBType D_DBDate = new NativeDBType(0xff, 6, true, false, OleDbType.DBDate, NativeDBType.DBDATE, S_DBDATE, typeof(System.DateTime), NativeDBType.DBDATE, DbType.Date ); // 6 - (tagDBDate) 166static private readonly NativeDBType D_DBTimeStamp = new NativeDBType(0xff, 16, true, false, OleDbType.DBTimeStamp, NativeDBType.DBTIMESTAMP, S_DBTIMESTAMP, typeof(System.DateTime), NativeDBType.DBTIMESTAMP, DbType.DateTime ); // 8 - (tagDBTIMESTAMP) 169static private readonly NativeDBType D_Filetime = new NativeDBType(0xff, 8, true, false, OleDbType.Filetime, NativeDBType.FILETIME, S_FILETIME, typeof(System.DateTime), NativeDBType.FILETIME, DbType.DateTime ); // 11 - integer8 // MDAC 59504
fx\src\data\System\Data\OleDb\OleDbDataReader.cs (1)
903override public DateTime GetDateTime(int ordinal) {
fx\src\data\System\Data\OleDb\PropertyInfoSet.cs (1)
150case VarEnum.VT_DATE: return typeof(System.DateTime);
fx\src\data\System\Data\ProviderBase\DbBuffer.cs (5)
586internal DateTime ReadDate(int offset) { 594internal void WriteDate(int offset, DateTime value) { 620internal DateTime ReadDateTime(int offset) { 624DateTime value = new DateTime( 633internal void WriteDateTime(int offset, DateTime value) {
fx\src\data\System\Data\ProviderBase\DbConnectionInternal.cs (4)
50private DateTime _createTime; // when the connection was created. 524DateTime now = DateTime.UtcNow; // WebData 111116 641_createTime = DateTime.UtcNow; // WebData 111116
fx\src\data\System\Data\ProviderBase\DbConnectionPoolAuthenticationContext.cs (5)
42private readonly DateTime _expirationTime; 54internal DbConnectionPoolAuthenticationContext(byte[] accessToken, DateTime expirationTime) { 57Debug.Assert(expirationTime > DateTime.MinValue && expirationTime < DateTime.MaxValue); 84internal DateTime ExpirationTime {
fx\src\data\System\Data\Sql\SqlMetaData.cs (6)
781public DateTime Adjust(DateTime value) { 1051case TypeCode.DateTime: value = this.Adjust((DateTime)value); break; 1446private static readonly DateTime x_dtSmallMax = new DateTime(2079, 06, 06, 23, 59, 29, 998); 1447private static readonly DateTime x_dtSmallMin = new DateTime(1899, 12, 31, 23, 59, 29, 999); 1448void VerifyDateTimeRange(DateTime value)
fx\src\data\System\Data\SqlClient\SqlBuffer.cs (10)
177internal DateTime DateTime { 182return DateTime.MinValue.AddDays(_value._int32); 190return (DateTime)this.Value; // anything else we haven't thought of goes through boxing. 764case SqlBuffer.StorageType.DateTime: return typeof(DateTime); 863internal void SetToDate(DateTime date) { 867_value._int32 = date.Subtract(DateTime.MinValue).Days; 897internal void SetToDateTime2(DateTime dateTime, byte scale) { 903_value._dateTime2Info.date = dateTime.Subtract(DateTime.MinValue).Days; 921DateTime utcDateTime = dateTimeOffset.UtcDateTime; // timeInfo stores the utc datetime of a datatimeoffset 924_value._dateTimeOffsetInfo.dateTime2Info.date = utcDateTime.Subtract(DateTime.MinValue).Days;
fx\src\data\System\Data\SqlClient\SqlBulkCopy.cs (2)
1991_parser.WriteSqlVariantDateTime2(((DateTime)value), _stateObj); 1994_parser.WriteSqlVariantDate(((DateTime)value), _stateObj);
fx\src\data\System\Data\SqlClient\SqlDataReader.cs (3)
2230override public DateTime GetDateTime(int i) { 2233DateTime dt = _data[i].DateTime; 2243dt = (DateTime) temp;
fx\src\data\System\Data\SqlClient\SqlDataReaderSmi.cs (1)
280public override DateTime GetDateTime(int ordinal) {
fx\src\data\System\Data\SqlClient\SqlDependency.cs (6)
238private DateTime _expirationTime = DateTime.MaxValue; 344internal DateTime ExpirationTime { 1038if (ExpirationTime < DateTime.UtcNow) { 1075if(_expirationTime == DateTime.MaxValue) { 1087_expirationTime = DateTime.UtcNow.AddSeconds(seconds);
fx\src\data\System\Data\SqlClient\SqlDependencyUtils.cs (6)
79private DateTime _nextTimeout; 509if (SingletonInstance._nextTimeout > DateTime.UtcNow) { 524DateTime now = DateTime.UtcNow; 525DateTime newNextTimeout = DateTime.MaxValue;
fx\src\data\System\Data\SqlClient\SqlEnums.cs (11)
406else if (sqlType == typeof(DateTime)) return DBNull.Value; 520else if (comVal is DateTime) { 522sqlVal = new SqlDateTime((DateTime)comVal); 791(23, 3, 8, true, false, false, TdsEnums.SQLDATETIME, TdsEnums.SQLDATETIMN, MetaTypeName.DATETIME, typeof(System.DateTime), typeof(SqlDateTime), SqlDbType.DateTime, DbType.DateTime, 0); 794(16, 0, 4, true, false, false, TdsEnums.SQLDATETIM4, TdsEnums.SQLDATETIMN, MetaTypeName.SMALLDATETIME, typeof(System.DateTime), typeof(SqlDateTime), SqlDbType.SmallDateTime, DbType.DateTime, 0); 823(255, 255, 3, true, false, false, TdsEnums.SQLDATE, TdsEnums.SQLDATE, MetaTypeName.DATE, typeof(System.DateTime), typeof(System.DateTime), SqlDbType.Date, DbType.Date, 0); 829(255, 7, -1, false, false, false, TdsEnums.SQLDATETIME2, TdsEnums.SQLDATETIME2, MetaTypeName.DATETIME2, typeof(System.DateTime), typeof(System.DateTime), SqlDbType.DateTime2, DbType.DateTime2, 1); 834public static TdsDateTime FromDateTime(DateTime dateTime, byte cb) { 856public static DateTime ToDateTime(int sqlDays, int sqlTime, int length) {
fx\src\data\System\Data\SqlClient\SqlInternalConnectionTds.cs (6)
2233TimeSpan contextValidity = dbConnectionPoolAuthenticationContext.ExpirationTime.Subtract(DateTime.UtcNow); 2238Bid.Trace("<sc.SqlInternalConnectionTds.OnFedAuthInfo> %d#, The expiration time is less than 10 mins, so trying to get new access token regardless of if an other thread is also trying to update it.The expiration time is %s. Current Time is %s.\n", ObjectID, dbConnectionPoolAuthenticationContext.ExpirationTime.ToLongTimeString(), DateTime.UtcNow.ToLongTimeString()); 2257Bid.Trace("<sc.SqlInternalConnectionTds.OnFedAuthInfo> %d#, The authentication context needs a refresh.The expiration time is %s. Current Time is %s.\n", ObjectID, dbConnectionPoolAuthenticationContext.ExpirationTime.ToLongTimeString(), DateTime.UtcNow.ToLongTimeString()); 2331Bid.Trace("<sc.SqlInternalConnectionTds.TryGetFedAuthTokenLocked> %d#, Acquired the lock to update the authentication context.The expiration time is %s. Current Time is %s.\n", ObjectID, dbConnectionPoolAuthenticationContext.ExpirationTime.ToLongTimeString(), DateTime.UtcNow.ToLongTimeString()); 2479DateTime expirationTime = DateTime.FromFileTimeUtc(fedAuthToken.expirationFileTime);
fx\src\data\System\Data\SqlClient\SqlParameter.cs (3)
688if (_value is DateTime) { 955else if ((typeof(DateTime) == currentType) && (SqlDbType.DateTimeOffset == destinationType.SqlDbType)) { 956value = new DateTimeOffset((DateTime)value);
fx\src\data\System\Data\SqlClient\TdsParser.cs (16)
5928TdsDateTime dt = MetaType.FromDateTime((DateTime)value, 8); 6087TdsDateTime dt = MetaType.FromDateTime((DateTime)value, 8); 6137internal void WriteSqlVariantDateTime2(DateTime value, TdsParserStateObject stateObj) 6146internal void WriteSqlVariantDate(DateTime value, TdsParserStateObject stateObj) 6249private byte[] SerializeDate(DateTime value) { 6250long days = value.Subtract(DateTime.MinValue).Days; 6254private void WriteDate(DateTime value, TdsParserStateObject stateObj) { 6255long days = value.Subtract(DateTime.MinValue).Days; 6281private byte[] SerializeDateTime2(DateTime value, byte scale, int length) { 6302private void WriteDateTime2(DateTime value, byte scale, int length, TdsParserStateObject stateObj) { 10655TdsDateTime dt = MetaType.FromDateTime((DateTime)value, (byte)type.FixedLength); 10677WriteDate((DateTime)value, stateObj); 10692WriteDateTime2((DateTime)value, scale, actualLength, stateObj); 10842TdsDateTime dt = MetaType.FromDateTime((DateTime)value, (byte)type.FixedLength); 10886return SerializeDate((DateTime)value); 10899return SerializeDateTime2((DateTime)value, scale, actualLength);
fx\src\data\System\Data\SqlClient\TdsParserStateObject.cs (6)
2225if (DateTime.UtcNow.Ticks - _lastSuccessfulIOTimer._value > CheckConnectionWindow) { 2260_lastSuccessfulIOTimer._value = DateTime.UtcNow.Ticks; 2287if (DateTime.UtcNow.Ticks - _lastSuccessfulIOTimer._value <= CheckConnectionWindow) { 2417_lastSuccessfulIOTimer._value = DateTime.UtcNow.Ticks; 2593_lastSuccessfulIOTimer._value = DateTime.UtcNow.Ticks; 2979_lastSuccessfulIOTimer._value = DateTime.UtcNow.Ticks;
fx\src\data\System\Data\SqlClient\TdsRecordBufferSetter.cs (1)
167public override void SetDateTime(SmiEventSink sink, int ordinal, DateTime value) {
fx\src\data\System\Data\SqlClient\TdsValueSetter.cs (4)
478internal void SetDateTime(DateTime value) { 516int days = value.Subtract(DateTime.MinValue).Days; 584DateTime utcDateTime = value.UtcDateTime; 586int days = utcDateTime.Subtract(DateTime.MinValue).Days;
fx\src\data\System\Data\SQLTypes\SQLDateTime.cs (18)
67private static readonly DateTime SQLBaseDate = new DateTime(1900, 1, 1); 86private static readonly DateTime MinDateTime = new DateTime(1753, 1, 1); 87private static readonly DateTime MaxDateTime = DateTime.MaxValue; 114public SqlDateTime(DateTime value) { 224private static DateTime ToDateTime(SqlDateTime value) { 229internal static DateTime ToDateTime(int daypart, int timepart) { 236DateTime result = new DateTime(SQLBaseDateTicks + dayticks + timeticks); 267private static SqlDateTime FromDateTime(DateTime value) { 275if (value == DateTime.MaxValue) 299public DateTime Value { 329public static implicit operator SqlDateTime(DateTime value) { 334public static explicit operator DateTime(SqlDateTime x) { 342DateTime dateTime = ToDateTime(this); 347DateTime dt; 353dt = DateTime.Parse(s, CultureInfo.InvariantCulture); 357dt = DateTime.ParseExact(s, x_DateTimeFormats, dtfi, x_DateTimeStyle); 633DateTime dt = XmlConvert.ToDateTime(reader.ReadElementString(), XmlDateTimeSerializationMode.RoundtripKind);
fx\src\data\System\Data\XDRSchema.cs (5)
221new NameType("date" , typeof(DateTime)), /* XDR */ 222new NameType("dateTime" , typeof(DateTime)), /* XDR */ 223new NameType("dateTime.tz" , typeof(DateTime)), /* XDR */ 244new NameType("time" , typeof(DateTime)), /* XDR */ 245new NameType("time.tz" , typeof(DateTime)), /* XDR */
fx\src\data\System\Data\xmlsaver.cs (2)
208if (type == typeof(DateTime) || type == typeof(SqlDateTime) ) 1172if (col.DataType == typeof(DateTime) && col.DateTimeMode != DataSetDateTime.UnspecifiedLocal) {
fx\src\data\System\Data\XMLSchema.cs (8)
1572new NameType("date" , typeof(DateTime)), /* XSD Apr */ 1573new NameType("dateTime" , typeof(DateTime)), /* XSD Apr */ 1578new NameType("gDay" , typeof(DateTime)), /* XSD Apr */ 1579new NameType("gMonth" , typeof(DateTime)), /* XSD Apr */ 1580new NameType("gMonthDay" , typeof(DateTime)), /* XSD Apr */ 1581new NameType("gYear" , typeof(DateTime)), /* XSD Apr */ 1582new NameType("gYearMonth" , typeof(DateTime)), /* XSD Apr */ 1595new NameType("time" , typeof(DateTime)), /* XSD Apr */
System.Data.Entity (118)
System\Data\Common\CommandTrees\AbstractExpressions.cs (3)
456/// Creates a <see cref="DbExpression"/> that represents the specified (nullable) <see cref="DateTime"/> value 460public static DbExpression FromDateTime(DateTime? value) 469public static implicit operator DbExpression(DateTime? value)
System\Data\Common\CommandTrees\Internal\ExpressionKeyGen.cs (1)
241_key.Append(((DateTime)e.Value).ToString("o", CultureInfo.InvariantCulture));
System\Data\Common\DataRecord.cs (2)
291public override DateTime GetDateTime(int ordinal) 293return ((DateTime)_values[ordinal]);
System\Data\Common\EntitySql\AST\Literal.cs (4)
498private static DateTime ConvertDateTimeLiteralValue(ErrorContext errCtx, string datetimeLiteralValue) 521DateTime dateTime = new DateTime(year, month, day, hour, minute, second, 0); 561DateTime dateTime = new DateTime(year, month, day, hour, minute, second, 0); 648if (day > DateTime.DaysInMonth(year, month))
System\Data\EntityClient\EntityDataReader.cs (1)
265public override DateTime GetDateTime(int ordinal)
System\Data\EntityModel\SchemaObjectModel\ScalarType.cs (4)
214DateTime temp; 215if (!DateTime.TryParseExact(text, DateTimeFormat, CultureInfo.InvariantCulture, DateTimeStyles.AssumeUniversal | DateTimeStyles.AdjustToUniversal, out temp)) 234DateTime temp; 235if (!DateTime.TryParseExact(text, TimeFormat, CultureInfo.InvariantCulture, DateTimeStyles.AssumeUniversal | DateTimeStyles.AdjustToUniversal | DateTimeStyles.NoCurrentDateDefault, out temp))
System\Data\Mapping\Update\Internal\Propagator.Evaluator.cs (2)
547if ( (value is DateTime) && (clrPrimitiveType == typeof(DateTimeOffset))) 549return new DateTimeOffset(((DateTime)value).Ticks, TimeSpan.Zero);
System\Data\Mapping\Update\Internal\Propagator.ExtentPlaceholderCreator.cs (1)
59typeDefaultMap[PrimitiveTypeKind.DateTime] = default(DateTime);
System\Data\Metadata\Edm\PrimitiveType.cs (1)
158return typeof(DateTime);
System\Data\Metadata\Edm\Provider\ClrProviderManifest.cs (1)
209primitiveTypes[(int)PrimitiveTypeKind.DateTime] = CreatePrimitiveType(typeof(DateTime), PrimitiveTypeKind.DateTime);
System\Data\Metadata\Edm\Provider\EdmProviderManifest.cs (1)
160InitializePrimitiveType(primitiveTypes[(int)PrimitiveTypeKind.DateTime], PrimitiveTypeKind.DateTime, EdmConstants.DateTime, typeof(DateTime));
System\Data\Objects\DataClasses\StructuralObject.cs (10)
120protected static DateTime DefaultDateTimeValue() 122return DateTime.Now; 550protected internal static DateTime SetValidValue(DateTime value, string propertyName) 566protected internal static DateTime SetValidValue(DateTime value) 584protected internal static Nullable<DateTime> SetValidValue(Nullable<DateTime> value, string propertyName) 600protected internal static Nullable<DateTime> SetValidValue(Nullable<DateTime> value)
System\Data\Objects\ELinq\MethodCallTranslator.cs (7)
1411yield return dateTimeType.GetMethod("Year", BindingFlags.Public | BindingFlags.Static, null, new Type[] { typeof(DateTime) }, null); 1412yield return dateTimeType.GetMethod("Month", BindingFlags.Public | BindingFlags.Static, null, new Type[] { typeof(DateTime) }, null); 1413yield return dateTimeType.GetMethod("Day", BindingFlags.Public | BindingFlags.Static, null, new Type[] { typeof(DateTime) }, null); 1414yield return dateTimeType.GetMethod("Hour", BindingFlags.Public | BindingFlags.Static, null, new Type[] { typeof(DateTime) }, null); 1415yield return dateTimeType.GetMethod("Minute", BindingFlags.Public | BindingFlags.Static, null, new Type[] { typeof(DateTime) }, null); 1416yield return dateTimeType.GetMethod("Second", BindingFlags.Public | BindingFlags.Static, null, new Type[] { typeof(DateTime) }, null); 1491new Type[] { dateIntervalEnum, typeof(DateTime), firstDayOfWeekEnum, firstWeekOfYearEnum }, null);
System\Data\Objects\ELinq\Translator.cs (9)
538yield return typeof(DateTime).GetProperty("Year", BindingFlags.Public | BindingFlags.Instance); 539yield return typeof(DateTime).GetProperty("Month", BindingFlags.Public | BindingFlags.Instance); 540yield return typeof(DateTime).GetProperty("Day", BindingFlags.Public | BindingFlags.Instance); 541yield return typeof(DateTime).GetProperty("Hour", BindingFlags.Public | BindingFlags.Instance); 542yield return typeof(DateTime).GetProperty("Minute", BindingFlags.Public | BindingFlags.Instance); 543yield return typeof(DateTime).GetProperty("Second", BindingFlags.Public | BindingFlags.Instance); 544yield return typeof(DateTime).GetProperty("Millisecond", BindingFlags.Public | BindingFlags.Instance); 573yield return GetProperty(typeof(DateTime), "Now", BindingFlags.Public | BindingFlags.Static, ExpressionConverter.CurrentDateTime); 574yield return GetProperty(typeof(DateTime), "UtcNow", BindingFlags.Public | BindingFlags.Static, ExpressionConverter.CurrentUtcDateTime);
System\Data\Objects\EntityFunctions.cs (39)
531public static System.DateTime? TruncateTime(System.DateTime? dateValue) 540public static System.DateTime? CreateDateTime(System.Int32? year, System.Int32? month, System.Int32? day, System.Int32? hour, System.Int32? minute, System.Double? second) 576public static System.DateTime? AddYears(System.DateTime? dateValue, System.Int32? addValue) 594public static System.DateTime? AddMonths(System.DateTime? dateValue, System.Int32? addValue) 612public static System.DateTime? AddDays(System.DateTime? dateValue, System.Int32? addValue) 630public static System.DateTime? AddHours(System.DateTime? timeValue, System.Int32? addValue) 657public static System.DateTime? AddMinutes(System.DateTime? timeValue, System.Int32? addValue) 684public static System.DateTime? AddSeconds(System.DateTime? timeValue, System.Int32? addValue) 711public static System.DateTime? AddMilliseconds(System.DateTime? timeValue, System.Int32? addValue) 738public static System.DateTime? AddMicroseconds(System.DateTime? timeValue, System.Int32? addValue) 765public static System.DateTime? AddNanoseconds(System.DateTime? timeValue, System.Int32? addValue) 792public static System.Int32? DiffYears(System.DateTime? dateValue1, System.DateTime? dateValue2) 810public static System.Int32? DiffMonths(System.DateTime? dateValue1, System.DateTime? dateValue2) 828public static System.Int32? DiffDays(System.DateTime? dateValue1, System.DateTime? dateValue2) 846public static System.Int32? DiffHours(System.DateTime? timeValue1, System.DateTime? timeValue2) 873public static System.Int32? DiffMinutes(System.DateTime? timeValue1, System.DateTime? timeValue2) 900public static System.Int32? DiffSeconds(System.DateTime? timeValue1, System.DateTime? timeValue2) 927public static System.Int32? DiffMilliseconds(System.DateTime? timeValue1, System.DateTime? timeValue2) 954public static System.Int32? DiffMicroseconds(System.DateTime? timeValue1, System.DateTime? timeValue2) 981public static System.Int32? DiffNanoseconds(System.DateTime? timeValue1, System.DateTime? timeValue2)
System\Data\Objects\ObjectStateEntryBaseUpdatableDataRecord.cs (3)
226override public DateTime GetDateTime(int ordinal) 228return (DateTime)GetValue(ordinal); 421public void SetDateTime(int ordinal, DateTime value)
System\Data\Objects\ObjectStateEntryDbDataRecord.cs (2)
174override public DateTime GetDateTime(int ordinal) 176return (DateTime)GetValue(ordinal);
System\Data\Objects\SqlClient\SqlFunctions.cs (23)
653public static System.DateTime? DateAdd(System.String datePartArg, System.Double? number, System.DateTime? date) 680public static System.DateTime? DateAdd(System.String datePartArg, System.Double? number, System.String date) 689public static System.Int32? DateDiff(System.String datePartArg, System.DateTime? startDate, System.DateTime? endDate) 716public static System.Int32? DateDiff(System.String datePartArg, System.String startDate, System.DateTime? endDate) 752public static System.Int32? DateDiff(System.String datePartArg, System.DateTime? startDate, System.String endDate) 779public static System.Int32? DateDiff(System.String datePartArg, System.TimeSpan? startDate, System.DateTime? endDate) 797public static System.Int32? DateDiff(System.String datePartArg, System.DateTime? startDate, System.TimeSpan? endDate) 815public static System.Int32? DateDiff(System.String datePartArg, System.DateTime? startDate, System.DateTimeOffset? endDate) 824public static System.Int32? DateDiff(System.String datePartArg, System.DateTimeOffset? startDate, System.DateTime? endDate) 833public static System.String DateName(System.String datePartArg, System.DateTime? date) 869public static System.Int32? DatePart(System.String datePartArg, System.DateTime? date) 905public static System.DateTime? GetDate() 914public static System.DateTime? GetUtcDate() 950public static System.Int32? DataLength(System.DateTime? arg) 1040public static System.Int32? Checksum(System.DateTime? arg1) 1121public static System.Int32? Checksum(System.DateTime? arg1, System.DateTime? arg2) 1202public static System.Int32? Checksum(System.DateTime? arg1, System.DateTime? arg2, System.DateTime? arg3) 1247public static System.DateTime? CurrentTimestamp()
System\Data\Query\ResultAssembly\BridgeDataReader.cs (1)
672override public DateTime GetDateTime(int ordinal) {
System\Data\Query\ResultAssembly\BridgeDataRecord.cs (2)
535override public DateTime GetDateTime(int ordinal) { 536return (DateTime)GetValue(ordinal);
System\Data\SqlClient\SqlGen\SqlGenerator.cs (1)
941result.Append(EscapeSingleQuote(((System.DateTime)e.Value).ToString(this.IsPreKatmai ? "yyyy-MM-dd HH:mm:ss.fff" : "yyyy-MM-dd HH:mm:ss.fffffff", CultureInfo.InvariantCulture), false /* IsUnicode */));
System.Data.Entity.Design (6)
System\Data\EntityModel\Emitters\NamespaceEmitter.cs (1)
72DateTime.Now.ToString( System.Globalization.CultureInfo.CurrentCulture ));
System\Data\EntityModel\Emitters\PropertyEmitter.cs (4)
768DateTime utc = (DateTime)value; 769DateTime dateTime = DateTime.SpecifyKind(utc, DateTimeKind.Unspecified);
System\Data\EntityModel\Emitters\TypeReference.cs (1)
271_dateTime = ForType(typeof(System.DateTime));
System.Data.Linq (78)
DbConvert.cs (7)
117else if (fromType == typeof(DateTime)) { 118return DateTime.Parse(value.ToString(), Globalization.CultureInfo.InvariantCulture).TimeOfDay; 131else if (toType == typeof(DateTime)) { 132DateTime dt = new DateTime(); 143else if (toType == typeof(DateTime) && fromType == typeof(DateTimeOffset)) { 146else if (toType == typeof(DateTimeOffset) && fromType == typeof(DateTime)) { 147return new DateTimeOffset((DateTime)value);
parent\DbmlShared\Mapping.cs (1)
535if (type == typeof(Guid) || type == typeof(DateTime) || type == typeof(DateTimeOffset) ||
SqlClient\Common\SqlFactory.cs (4)
84return UnaryConvert(typeof(DateTime), typeProvider.From(typeof(DateTime)), expr, expr.SourceExpression); 204Type returnType = asNullable ? typeof(DateTime?) : typeof(DateTime);
SqlClient\Query\QueryConverter.cs (1)
700return sql.FunctionCall(typeof(DateTime), "CONVERT", new SqlExpression[2] { datetime2, expr }, expr.SourceExpression);
SqlClient\Query\SqlMethodCallConverter.cs (22)
59else if (snew.ClrType == typeof(DateTime)) { 70if (sox.ClrType == typeof(DateTime) 244if (!mc.Method.IsStatic && mc.Method.DeclaringType == typeof(DateTime)) { 321if (mc.Arguments[0].ClrType == typeof(string) || mc.Arguments[0].ClrType == typeof(DateTime)) { 554if (m.Expression.ClrType == typeof(DateTime)) { 666if (leftType == typeof(DateTime) || leftType == typeof(DateTimeOffset)) { 708else if (sox.ClrType == typeof(DateTime)) { 732if (sox.ClrType == typeof(DateTime) && sox.Args.Count >= 3 && 742return sql.FunctionCall(typeof(DateTime), "CONVERT", new SqlExpression[3] { datetime, date, sql.ValueFromObject(101, false, source) }, source); 756return sql.FunctionCall(typeof(DateTime), "CONVERT", new SqlExpression[3] { datetime, dateAndTime, sql.ValueFromObject(120, false, source) }, source); 774return sql.FunctionCall(typeof(DateTime), "CONVERT", new SqlExpression[3] { datetime, dateAndTime, sql.ValueFromObject(121, false, source) }, source); 786if (sox.Args.Count == 1 && sox.Args[0].ClrType == typeof(DateTime)) { 793if (sox.Args.Count == 2 && sox.Args[0].ClrType == typeof(DateTime) && sox.Args[1].ClrType == typeof(TimeSpan)) { 969else if (declType == typeof(DateTime)) { 1223if (nnType == typeof(string) || nnType == typeof(DateTime)) { 1224targetType = typeof(DateTime); 1289if (rightType == typeof(DateTime)) { 1302typeof(DateTime), "DATEADD", new SqlExpression[] { day, intDays, start }, bo.SourceExpression); 2178else if (baseClrTypeOfExpr == typeof(DateTime) || baseClrTypeOfExpr == typeof(DateTimeOffset)) { 2186return sql.FunctionCall(typeof(DateTime), "CONVERT", new SqlExpression[2] { date, exp }, source); 2211return sql.FunctionCall(typeof(DateTime), "CONVERT", new SqlExpression[2] { datetime, exp }, source); 2403targetType = typeof(DateTime);
SqlClient\Query\SqlMethodTransformer.cs (1)
85return (expected == typeof(DateTime) && actual == typeof(DateTimeOffset));
SqlClient\Query\SqlParameterizer.cs (3)
121pi = new SqlParameterInfo(p, ((DateTime)cp.Value).TimeOfDay); 151if (isLeftColRef && leftSqlDbType == SqlDbType.Time && bo.Right.ClrType == typeof(DateTime)) 153else if (isRightColRef && rightSqlDbType == SqlDbType.Time && bo.Left.ClrType == typeof(DateTime))
SqlClient\Reader\ObjectReaderCompiler.cs (1)
2941public override DateTime GetDateTime(int i) { return reader.GetDateTime(i); }
SqlClient\SqlMethods.cs (36)
20public static int DateDiffYear(DateTime startDate, DateTime endDate) { 32public static int? DateDiffYear(DateTime? startDate, DateTime? endDate) { 79public static int DateDiffMonth(DateTime startDate, DateTime endDate) { 90public static int? DateDiffMonth(DateTime? startDate, DateTime? endDate) { 137public static int DateDiffDay(DateTime startDate, DateTime endDate) { 149public static int? DateDiffDay(DateTime? startDate, DateTime? endDate) { 195public static int DateDiffHour(DateTime startDate, DateTime endDate) { 208public static int? DateDiffHour(DateTime? startDate, DateTime? endDate) { 254public static int DateDiffMinute(DateTime startDate, DateTime endDate) { 267public static int? DateDiffMinute(DateTime? startDate, DateTime? endDate) { 314public static int DateDiffSecond(DateTime startDate, DateTime endDate) { 327public static int? DateDiffSecond(DateTime? startDate, DateTime? endDate) { 374public static int DateDiffMillisecond(DateTime startDate, DateTime endDate) { 387public static int? DateDiffMillisecond(DateTime? startDate, DateTime? endDate) { 434public static int DateDiffMicrosecond(DateTime startDate, DateTime endDate) 449public static int? DateDiffMicrosecond(DateTime? startDate, DateTime? endDate) 500public static int DateDiffNanosecond(DateTime startDate, DateTime endDate) 515public static int? DateDiffNanosecond(DateTime? startDate, DateTime? endDate)
SqlClient\SqlTypeSystemProvider.cs (2)
96return typeof(DateTime); 1168return From(typeof(DateTime));
System.Data.Services (28)
System\Data\Services\Epm\EpmSyndicationContentSerializer.cs (4)
173else if (propertyValue is DateTime) 177date = new DateTimeOffset((DateTime)propertyValue); 183DateTime result; 184if (!DateTime.TryParse((String)propertyValue, out result))
System\Data\Services\Parsing\FunctionDescription.cs (1)
518CreateFunctionDescription(typeof(DateTime), true /* instance */, false /* method */, name, Type.EmptyTypes)
System\Data\Services\Parsing\OperationSignatures.cs (4)
112void F(DateTime x, DateTime y); 120void F(DateTime? x, DateTime? y);
System\Data\Services\Parsing\RequestQueryParser.cs (1)
1774return this.ParseTypedLiteral(typeof(DateTime), XmlConstants.EdmDateTimeTypeName, l);
System\Data\Services\Parsing\WebConvert.cs (10)
155if (value.GetType() == typeof(DateTime)) 282internal static bool TryKeyStringToDateTime(string text, out DateTime targetValue) 286targetValue = default(DateTime); 292targetValue = default(DateTime); 303targetValue = default(DateTime); 374else if (targetType == typeof(DateTime)) 376DateTime dateTimeValue; 530else if (typeof(DateTime) == targetType) 635else if (typeof(DateTime) == valueType) 637result = XmlConvert.ToString((DateTime)value, XmlDateTimeSerializationMode.RoundtripKind);
System\Data\Services\Providers\ObjectContextServiceProvider.cs (2)
1587else if (facetValueType == typeof(DateTime)) 1589xmlWriter.WriteAttributeString(facetName, XmlConvert.ToString((DateTime)facetValue, "yyyy-MM-dd HH:mm:ss.fffZ"));
System\Data\Services\Serializers\JsonReader.cs (1)
93DateTime dateTime = new DateTime(ticks * 10000 + JsonWriter.DatetimeMinTimeTicks, DateTimeKind.Utc);
System\Data\Services\Serializers\JsonSerializer.cs (2)
337else if (typeof(DateTime) == value.GetType()) 339this.writer.WriteValue((DateTime)value);
System\Data\Services\Serializers\JsonWriter.cs (1)
258public void WriteValue(DateTime dateTime)
System\Data\Services\WebUtil.cs (2)
74new KeyValuePair<Type, string>(typeof(DateTime), XmlConstants.EdmDateTimeTypeName), 75new KeyValuePair<Type, string>(typeof(DateTime?), XmlConstants.EdmDateTimeTypeName),
System.Data.Services.Client (28)
parent\Server\System\Data\Services\Parsing\WebConvert.cs (3)
155if (value.GetType() == typeof(DateTime)) 635else if (typeof(DateTime) == valueType) 637result = XmlConvert.ToString((DateTime)value, XmlDateTimeSerializationMode.RoundtripKind);
System\Data\Services\Client\ALinq\TypeSystem.cs (18)
64expressionMethodMap.Add(typeof(DateTime).GetProperty("Day", typeof(int)).GetGetMethod(), @"day"); 65expressionMethodMap.Add(typeof(DateTime).GetProperty("Hour", typeof(int)).GetGetMethod(), @"hour"); 66expressionMethodMap.Add(typeof(DateTime).GetProperty("Month", typeof(int)).GetGetMethod(), @"month"); 67expressionMethodMap.Add(typeof(DateTime).GetProperty("Minute", typeof(int)).GetGetMethod(), @"minute"); 68expressionMethodMap.Add(typeof(DateTime).GetProperty("Second", typeof(int)).GetGetMethod(), @"second"); 69expressionMethodMap.Add(typeof(DateTime).GetProperty("Year", typeof(int)).GetGetMethod(), @"year"); 108typeof(DateTime).GetProperty("Day", typeof(int)), 109typeof(DateTime).GetProperty("Day", typeof(int)).GetGetMethod()); 111typeof(DateTime).GetProperty("Hour", typeof(int)), 112typeof(DateTime).GetProperty("Hour", typeof(int)).GetGetMethod()); 114typeof(DateTime).GetProperty("Minute", typeof(int)), 115typeof(DateTime).GetProperty("Minute", typeof(int)).GetGetMethod()); 117typeof(DateTime).GetProperty("Second", typeof(int)), 118typeof(DateTime).GetProperty("Second", typeof(int)).GetGetMethod()); 120typeof(DateTime).GetProperty("Month", typeof(int)), 121typeof(DateTime).GetProperty("Month", typeof(int)).GetGetMethod()); 123typeof(DateTime).GetProperty("Year", typeof(int)), 124typeof(DateTime).GetProperty("Year", typeof(int)).GetGetMethod());
System\Data\Services\Client\ClientConvert.cs (4)
311DateTime dt = (DateTime)propertyValue; 468types[(int)StorageType.DateTime] = typeof(DateTime); 502named.Add(XmlConstants.EdmDateTimeTypeName, typeof(DateTime));
System\Data\Services\Client\DataServiceContext.cs (1)
2943writer.WriteElementString(XmlConstants.AtomUpdatedElementName, XmlConstants.AtomNamespace, XmlConvert.ToString(DateTime.UtcNow, XmlDateTimeSerializationMode.RoundtripKind));
System\Data\Services\Client\Epm\EpmSyndicationContentSerializer.cs (2)
116atomDateConstruct ? ClientConvert.ToString(DateTime.MinValue, atomDateConstruct) : 227this.Target.WriteElementString(XmlConstants.AtomUpdatedElementName, XmlConstants.AtomNamespace, XmlConvert.ToString(DateTime.UtcNow, XmlDateTimeSerializationMode.RoundtripKind));
System.Data.Services.Design (6)
System\Data\EntityModel\Emitters\NamespaceEmitter.cs (1)
138DateTime.Now.ToString(System.Globalization.CultureInfo.CurrentCulture));
System\Data\EntityModel\Emitters\PropertyEmitter.cs (4)
702DateTime utc = (DateTime)value; 703DateTime dateTime = DateTime.SpecifyKind(utc, DateTimeKind.Unspecified);
System\Data\EntityModel\Emitters\TypeReference.cs (1)
223_dateTime = ForType(typeof(System.DateTime));
System.Data.SqlXml (34)
System\Xml\Xsl\IlGen\GenerateHelper.cs (4)
112else if (storageType == typeof(DateTime)) 361public static readonly MethodInfo DTToStr = GetMethod(typeof(XsltConvert), "ToString", typeof(DateTime)); 406StorageMethods[typeof(DateTime)] = new XmlILStorageMethods(typeof(DateTime));
System\Xml\Xsl\IlGen\XmlIlTypeHelper.cs (16)
71typeof(DateTime), // XmlTypeCode.DateTime 72typeof(DateTime), // XmlTypeCode.Time 73typeof(DateTime), // XmlTypeCode.Date 74typeof(DateTime), // XmlTypeCode.GYearMonth 75typeof(DateTime), // XmlTypeCode.GYear 76typeof(DateTime), // XmlTypeCode.GMonthDay 77typeof(DateTime), // XmlTypeCode.GDay 78typeof(DateTime), // XmlTypeCode.GMonth 129typeof(IList<DateTime>), // XmlTypeCode.DateTime 130typeof(IList<DateTime>), // XmlTypeCode.Time 131typeof(IList<DateTime>), // XmlTypeCode.Date 132typeof(IList<DateTime>), // XmlTypeCode.GYearMonth 133typeof(IList<DateTime>), // XmlTypeCode.GYear 134typeof(IList<DateTime>), // XmlTypeCode.GMonthDay 135typeof(IList<DateTime>), // XmlTypeCode.GDay 136typeof(IList<DateTime>), // XmlTypeCode.GMonth
System\Xml\Xsl\Runtime\XmlILStorageConverter.cs (1)
60public static XmlAtomicValue DateTimeToAtomicValue(DateTime value, int index, XmlQueryRuntime runtime) {
System\Xml\Xsl\Runtime\XmlQueryRuntime.cs (2)
557value = XsltConvert.ToString((DateTime) value); 612value = new XmlQueryItemSequence(new XmlAtomicValue(XmlSchemaType.GetBuiltInSimpleType(XmlTypeCode.String), XsltConvert.ToString((DateTime) value)));
System\Xml\Xsl\Runtime\XmlRawWriterWrapper.cs (1)
114public override void WriteValue(DateTime value) {
System\Xml\Xsl\Runtime\XmlSortKey.cs (1)
327public XmlDateTimeSortKey(DateTime value, XmlCollation collation) : base(value.Ticks, collation) {
System\Xml\Xsl\Runtime\XmlSortKeyAccumulator.cs (1)
62public void AddDateTimeSortKey(XmlCollation collation, DateTime value) {
System\Xml\Xsl\Runtime\XsltConvert.cs (4)
34internal static readonly Type DateTimeType = typeof(DateTime); 219public static string ToString(DateTime value) { 252public static DateTime ToDateTime(string value) { 253return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.AllXsd));
System\Xml\Xsl\Runtime\XsltFunctions.cs (4)
317public SystemTime(DateTime dateTime) { 416DateTime dt; 514private static void PrintDate(char[] text, DateTime dt) { 520private static void PrintTime(char[] text, DateTime dt) {
System.Drawing (1)
commonui\System\Drawing\Design\UITypeEditor.cs (1)
40intrinsicEditors[typeof(DateTime)] = "System.ComponentModel.Design.DateTimeEditor, " + AssemblyRef.SystemDesign;
System.IdentityModel (308)
System\IdentityModel\BoundedCache.cs (8)
20DateTime _nextPurgeTime = DateTime.UtcNow; 185DateTime currentTime = DateTime.UtcNow; 246public virtual bool TryAdd(string key, T item, DateTime expirationTime) 370DateTime _expirationTime; 373public ExpirableItem(ET item, DateTime expirationTime) 388return (_expirationTime <= DateTime.UtcNow);
System\IdentityModel\Claims\AuthenticationInformation.cs (2)
18DateTime? _notOnOrAfter; 58public DateTime? NotOnOrAfter
System\IdentityModel\Claims\WindowsClaimSet.cs (8)
21DateTime expirationTime; 34: this(windowsIdentity, includeWindowsGroups, DateTime.UtcNow.AddHours(10)) 38public WindowsClaimSet(WindowsIdentity windowsIdentity, DateTime expirationTime) 43public WindowsClaimSet(WindowsIdentity windowsIdentity, bool includeWindowsGroups, DateTime expirationTime) 48public WindowsClaimSet(WindowsIdentity windowsIdentity, string authenticationType, bool includeWindowsGroups, DateTime expirationTime) 54: this( windowsIdentity, authenticationType, includeWindowsGroups, DateTime.UtcNow.AddHours( 10 ), clone ) 58internal WindowsClaimSet(WindowsIdentity windowsIdentity, string authenticationType, bool includeWindowsGroups, DateTime expirationTime, bool clone) 117public DateTime ExpirationTime
System\IdentityModel\Claims\X509CertificateClaimSet.cs (2)
20DateTime expirationTime = SecurityUtils.MinUtcDateTime; 83public DateTime ExpirationTime
System\IdentityModel\DateTimeUtil.cs (15)
17/// <param name="time">Initial <see cref="DateTime"/> value.</param> 20public static DateTime Add(DateTime time, TimeSpan timespan) 22if (timespan >= TimeSpan.Zero && DateTime.MaxValue - time <= timespan) 27if (timespan <= TimeSpan.Zero && DateTime.MinValue - time >= timespan) 43public static DateTime AddNonNegative(DateTime time, TimeSpan timespan) 52public static DateTime GetMaxValue(DateTimeKind kind) 54return new DateTime(DateTime.MaxValue.Ticks, kind); 57public static DateTime GetMinValue(DateTimeKind kind) 59return new DateTime(DateTime.MinValue.Ticks, kind); 62public static DateTime? ToUniversalTime(DateTime? value) 71public static DateTime ToUniversalTime(DateTime value)
System\IdentityModel\IdentityModelWrappedXmlDictionaryReader.cs (1)
375public override DateTime ReadContentAsDateTime()
System\IdentityModel\Metadata\MetadataSerializer.cs (3)
1400DateTime validUntil; 1401if (!DateTime.TryParse(validUntilString, out validUntil)) 2764if (roleDescriptor.ValidUntil != null && roleDescriptor.ValidUntil != DateTime.MaxValue)
System\IdentityModel\Metadata\RoleDescriptor.cs (3)
21DateTime validUntil = DateTime.MaxValue; 85public DateTime ValidUntil
System\IdentityModel\Policy\AuthorizationContext.cs (1)
16public abstract DateTime ExpirationTime { get; }
System\IdentityModel\Policy\DefaultAuthorizationContext.cs (2)
16DateTime expirationTime; 58public override DateTime ExpirationTime
System\IdentityModel\Policy\DefaultEvaluationContext.cs (3)
16DateTime expirationTime = SecurityUtils.MaxUtcDateTime; 51public DateTime ExpirationTime 68public override void RecordExpirationTime(DateTime expirationTime)
System\IdentityModel\Policy\EvaluationContext.cs (1)
17public abstract void RecordExpirationTime(DateTime expirationTime);
System\IdentityModel\Policy\UnconditionalPolicy.cs (7)
23DateTime expirationTime; 33public UnconditionalPolicy(ClaimSet issuance, DateTime expirationTime) 41public UnconditionalPolicy(ReadOnlyCollection<ClaimSet> issuances, DateTime expirationTime) 55internal UnconditionalPolicy(IIdentity primaryIdentity, ClaimSet issuance, DateTime expirationTime) 61internal UnconditionalPolicy(IIdentity primaryIdentity, ReadOnlyCollection<ClaimSet> issuances, DateTime expirationTime) 83void Initialize(ClaimSet issuer, ClaimSet issuance, ReadOnlyCollection<ClaimSet> issuances, DateTime expirationTime) 173public DateTime ExpirationTime
System\IdentityModel\Protocols\WSTrust\Lifetime.cs (10)
18DateTime? _created; 19DateTime? _expires; 28public Lifetime( DateTime created, DateTime expires ) 29: this( (DateTime?)created, (DateTime?)expires ) 40public Lifetime( DateTime? created, DateTime? expires ) 52public DateTime? Created 67public DateTime? Expires
System\IdentityModel\Protocols\WSTrust\WSTrustSerializationHelper.cs (4)
2525DateTime? created = null; 2526DateTime? expires = null; 2536created = DateTime.ParseExact(reader.ReadString(), DateTimeFormats.Accepted, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.None).ToUniversalTime(); 2543expires = DateTime.ParseExact(reader.ReadString(), DateTimeFormats.Accepted, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.None).ToUniversalTime();
System\IdentityModel\SamlDelegatingWriter.cs (3)
154public override void WriteArray(string prefix, string localName, string namespaceUri, DateTime[] array, int offset, int count) 204public override void WriteArray(string prefix, XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count) 426public override void WriteValue(DateTime value)
System\IdentityModel\SecurityTokenService.cs (8)
459DateTime created; 460DateTime expires; 464created = DateTime.UtcNow; 475created = DateTime.UtcNow; 493private void VerifyComputedLifetime(DateTime created, DateTime expires) 496DateTime utcNow = DateTime.UtcNow;
System\IdentityModel\SecurityUtils.cs (14)
51public static DateTime MaxUtcDateTime 56return new DateTime(DateTime.MaxValue.Ticks - TimeSpan.TicksPerDay, DateTimeKind.Utc); 60public static DateTime MinUtcDateTime 65return new DateTime(DateTime.MinValue.Ticks + TimeSpan.TicksPerDay, DateTimeKind.Utc); 168internal static bool IsCurrentlyTimeEffective(DateTime effectiveTime, DateTime expirationTime, TimeSpan maxClockSkew) 170DateTime curEffectiveTime = (effectiveTime < DateTime.MinValue.Add(maxClockSkew)) ? effectiveTime : effectiveTime.Subtract(maxClockSkew); 171DateTime curExpirationTime = (expirationTime > DateTime.MaxValue.Subtract(maxClockSkew)) ? expirationTime : expirationTime.Add(maxClockSkew); 172DateTime curTime = DateTime.UtcNow; 354public override DateTime ExpirationTime { get { return this.policy.ExpirationTime; } } 602internal static ReadOnlyCollection<IAuthorizationPolicy> CreateAuthorizationPolicies(ClaimSet claimSet, DateTime expirationTime)
System\IdentityModel\Selectors\SamlSecurityTokenAuthenticator.cs (1)
79throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new SecurityTokenException(SR.GetString(SR.SAMLTokenTimeInvalid, DateTime.UtcNow.ToUniversalTime(), samlToken.ValidFrom.ToString(), samlToken.ValidTo.ToString())));
System\IdentityModel\Selectors\X509CertificateChain.cs (2)
86chainPolicy.VerificationTime = DateTime.Now; 147DateTime verificationTime,
System\IdentityModel\Selectors\X509CertificateValidator.cs (2)
160DateTime now = DateTime.Now;
System\IdentityModel\SspiWrapper.cs (10)
125DateTime effectiveTimeUtc; 126DateTime expiryTimeUtc; 128internal DateTime EffectiveTimeUtc 136internal DateTime ExpiryTimeUtc 153this.effectiveTimeUtc = DateTime.FromFileTimeUtc(lifeSpan.start) + (DateTime.UtcNow - DateTime.Now); 154this.expiryTimeUtc = DateTime.FromFileTimeUtc(lifeSpan.end) + (DateTime.UtcNow - DateTime.Now);
System\IdentityModel\Tokens\DefaultTokenReplayCache.cs (3)
107public override void AddOrUpdate(string key, SecurityToken securityToken, DateTime expirationTime) 109if (DateTime.Equals(expirationTime, DateTime.MaxValue))
System\IdentityModel\Tokens\EncryptedSecurityToken.cs (2)
111public override DateTime ValidFrom 119public override DateTime ValidTo
System\IdentityModel\Tokens\GenericXmlSecurityToken.cs (6)
28DateTime effectiveTime; 29DateTime expirationTime; 34DateTime effectiveTime, 35DateTime expirationTime, 62public override DateTime ValidFrom 67public override DateTime ValidTo
System\IdentityModel\Tokens\KerberosReceiverSecurityToken.cs (4)
94public override DateTime ValidFrom 106public override DateTime ValidTo 254DateTime effectiveTime = lifeSpan.EffectiveTimeUtc; 255DateTime expirationTime = lifeSpan.ExpiryTimeUtc;
System\IdentityModel\Tokens\KerberosRequestorSecurityToken.cs (4)
24DateTime effectiveTime; 25DateTime expirationTime; 98public override DateTime ValidFrom 103public override DateTime ValidTo
System\IdentityModel\Tokens\KerberosSecurityTokenHandler.cs (1)
98wi.AddClaim(new Claim(ClaimTypes.AuthenticationInstant, XmlConvert.ToString(DateTime.UtcNow, DateTimeFormats.Generated), ClaimValueTypes.DateTime));
System\IdentityModel\Tokens\MruSessionSecurityTokenCache.cs (3)
31private DateTime nextPurgeTime = DateTime.UtcNow + DefaultPurgeInterval; 151public override void AddOrUpdate(SessionSecurityTokenCacheKey key, SessionSecurityToken value, DateTime expirationTime)
System\IdentityModel\Tokens\RsaSecurityToken.cs (5)
18DateTime effectiveTime; 37this.effectiveTime = DateTime.UtcNow; 53this.effectiveTime = DateTime.UtcNow; 155public override DateTime ValidFrom 160public override DateTime ValidTo
System\IdentityModel\Tokens\RsaSecurityTokenHandler.cs (1)
171identity.AddClaim(new Claim(ClaimTypes.AuthenticationInstant, XmlConvert.ToString(DateTime.UtcNow, DateTimeFormats.Generated), ClaimValueTypes.DateTime));
System\IdentityModel\Tokens\Saml2Assertion.cs (3)
23private DateTime issueInstant = DateTime.UtcNow; 135public DateTime IssueInstant
System\IdentityModel\Tokens\Saml2AuthenticationStatement.cs (6)
17private DateTime authnInstant; 19private DateTime? sessionNotOnOrAfter; 27: this(authenticationContext, DateTime.UtcNow) 36public Saml2AuthenticationStatement(Saml2AuthenticationContext authenticationContext, DateTime authenticationInstant) 72public DateTime AuthenticationInstant 93public DateTime? SessionNotOnOrAfter
System\IdentityModel\Tokens\Saml2Conditions.cs (4)
18private DateTime? notBefore; 19private DateTime? notOnOrAfter; 43public DateTime? NotBefore 71public DateTime? NotOnOrAfter
System\IdentityModel\Tokens\Saml2SecurityToken.cs (4)
88public override DateTime ValidFrom 98return DateTime.MinValue; 106public override DateTime ValidTo 116return DateTime.MaxValue;
System\IdentityModel\Tokens\Saml2SecurityTokenHandler.cs (14)
1378DateTime authInstantTime = DateTime.ParseExact(authenticationInstant, DateTimeFormats.Accepted, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.None).ToUniversalTime(); 1559DateTime now = DateTime.UtcNow; 1710protected virtual DateTime GetTokenReplayCacheEntryExpirationTime(Saml2SecurityToken token) 1717DateTime? tokenExpiration = null; 1737DateTime maximumExpirationTime = DateTimeUtil.Add(DateTime.UtcNow, Configuration.TokenReplayCacheExpirationPeriod); 1740tokenExpiration = tokenExpiration ?? DateTime.MaxValue; 1743if (DateTime.Compare(maximumExpirationTime, tokenExpiration.Value) < 0) 2113DateTime now = DateTime.UtcNow; 3694DateTime authnInstant; 3697DateTime? sessionNotOnOrAfter = null;
System\IdentityModel\Tokens\Saml2SubjectConfirmationData.cs (4)
21private DateTime? notBefore; 22private DateTime? notOnOrAfter; 70public DateTime? NotBefore 79public DateTime? NotOnOrAfter
System\IdentityModel\Tokens\SamlAssertion.cs (5)
25DateTime issueInstant = DateTime.UtcNow.ToUniversalTime(); 51DateTime issueInstant, 153public DateTime IssueInstant 532this.issueInstant = DateTime.ParseExact(
System\IdentityModel\Tokens\SamlAuthenticationClaimResource.cs (5)
18DateTime authenticationInstant; 40DateTime authenticationInstant, 57DateTime authenticationInstant, 79DateTime authenticationInstant, 94public DateTime AuthenticationInstant
System\IdentityModel\Tokens\SamlAuthenticationStatement.cs (5)
19DateTime authenticationInstant = DateTime.UtcNow.ToUniversalTime(); 32DateTime authenticationInstant, 60public DateTime AuthenticationInstant 179this.authenticationInstant = DateTime.ParseExact(
System\IdentityModel\Tokens\SamlConditions.cs (10)
22DateTime notBefore = SecurityUtils.MinUtcDateTime; 23DateTime notOnOrAfter = SecurityUtils.MaxUtcDateTime; 29public SamlConditions(DateTime notBefore, DateTime notOnOrAfter) 34public SamlConditions(DateTime notBefore, DateTime notOnOrAfter, 58public DateTime NotBefore 70public DateTime NotOnOrAfter 115this.notBefore = DateTime.ParseExact( 120this.notOnOrAfter = DateTime.ParseExact(
System\IdentityModel\Tokens\SamlSecurityToken.cs (2)
65public override DateTime ValidFrom 78public override DateTime ValidTo
System\IdentityModel\Tokens\SamlSecurityTokenHandler.cs (17)
48static DateTime WCFMinValue = new DateTime(DateTime.MinValue.Ticks + TimeSpan.TicksPerDay, DateTimeKind.Utc); 49static DateTime WCFMaxValue = new DateTime(DateTime.MaxValue.Ticks - TimeSpan.TicksPerDay, DateTimeKind.Utc); 237return new SamlAssertion(System.IdentityModel.UniqueId.CreateRandomId(), issuer, DateTime.UtcNow, conditions, advice, statements); 390DateTime authInstantTime = DateTime.ParseExact(authenticationInstant, 854protected virtual DateTime GetTokenReplayCacheEntryExpirationTime(SamlSecurityToken token) 864DateTime maximumExpirationTime = DateTimeUtil.Add(DateTime.UtcNow, Configuration.TokenReplayCacheExpirationPeriod); 867if (DateTime.Compare(maximumExpirationTime, token.ValidTo) < 0) 891DateTime now = DateTime.UtcNow; 1804assertion.IssueInstant = DateTime.ParseExact( 1925conditions.NotBefore = DateTime.ParseExact( 1932conditions.NotOnOrAfter = DateTime.ParseExact( 2861authnStatement.AuthenticationInstant = DateTime.ParseExact(
System\IdentityModel\Tokens\SecurityToken.cs (2)
13public abstract DateTime ValidFrom { get; } 14public abstract DateTime ValidTo { get; }
System\IdentityModel\Tokens\SecurityTokenDescriptor.cs (2)
235this.AddAuthenticationClaims(authType, DateTime.UtcNow); 244public void AddAuthenticationClaims(string authType, DateTime time)
System\IdentityModel\Tokens\SessionSecurityToken.cs (35)
58DateTime _keyEffectiveTime; 59DateTime _keyExpirationTime; 63DateTime _validFrom; 64DateTime _validTo; 83: this(claimsPrincipal, null, DateTime.UtcNow, DateTimeUtil.AddNonNegative(DateTime.UtcNow, lifetime)) 93: this(claimsPrincipal, context, DateTime.UtcNow, DateTimeUtil.AddNonNegative(DateTime.UtcNow, SessionSecurityTokenHandler.DefaultTokenLifetime)) 103public SessionSecurityToken(ClaimsPrincipal claimsPrincipal, string context, DateTime? validFrom, DateTime? validTo) 115public SessionSecurityToken(ClaimsPrincipal claimsPrincipal, string context, string endpointId, DateTime? validFrom, DateTime? validTo) 135: this(claimsPrincipal, contextId, context, endpointId, DateTime.UtcNow, lifetime, key) 154DateTime validFrom, 183DateTime? validFrom, 184DateTime? validTo, 213DateTime? validFrom, 214DateTime? validTo, 216DateTime? keyEffectiveTime, 217DateTime? keyExpirationTime, 239DateTime validFromEffective; 240DateTime validToEffective; 248validFromEffective = DateTime.UtcNow; 265if (validToEffective < DateTime.UtcNow) 277keyEffectiveTime = (DateTime?)validFromEffective; 282keyExpirationTime = (DateTime?)validToEffective; 465DateTime effectiveTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 471DateTime expiryTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 477DateTime keyEffectiveTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 483DateTime keyExpiryTime = new DateTime(XmlUtil.ReadElementContentAsInt64(reader), DateTimeKind.Utc); 575public DateTime KeyEffectiveTime 583public DateTime KeyExpirationTime 662public override DateTime ValidFrom 670public override DateTime ValidTo 1062rnd = new Random(unchecked((int)DateTime.Now.Ticks));
System\IdentityModel\Tokens\SessionSecurityTokenCache.cs (1)
33public abstract void AddOrUpdate(SessionSecurityTokenCacheKey key, SessionSecurityToken value, DateTime expiryTime);
System\IdentityModel\Tokens\SessionSecurityTokenHandler.cs (12)
261DateTime validFrom = (tokenDescriptor.Lifetime.Created.HasValue) ? (DateTime)tokenDescriptor.Lifetime.Created : DateTime.UtcNow; 262DateTime validTo = (tokenDescriptor.Lifetime.Expires.HasValue) ? (DateTime)tokenDescriptor.Lifetime.Expires : DateTime.UtcNow + SessionSecurityTokenHandler.DefaultTokenLifetime; 279DateTime validFrom, 280DateTime validTo) 686DateTime utcNow = DateTime.UtcNow; 689DateTime maxTime = DateTimeUtil.Add(utcNow, Configuration.MaxClockSkew); 690DateTime minTime = DateTimeUtil.Add(utcNow, -Configuration.MaxClockSkew);
System\IdentityModel\Tokens\TokenReplayCache.cs (1)
31public abstract void AddOrUpdate(string key, SecurityToken securityToken, DateTime expirationTime);
System\IdentityModel\Tokens\UserNameSecurityToken.cs (4)
14DateTime effectiveTime; 31this.effectiveTime = DateTime.UtcNow; 44public override DateTime ValidFrom 49public override DateTime ValidTo
System\IdentityModel\Tokens\WindowsSecurityToken.cs (11)
18DateTime effectiveTime; 19DateTime expirationTime; 35DateTime effectiveTime = DateTime.UtcNow; 36Initialize( id, authenticationType, effectiveTime, DateTime.UtcNow.AddHours( 10 ), windowsIdentity, true ); 43protected void Initialize(string id, DateTime effectiveTime, DateTime expirationTime, WindowsIdentity windowsIdentity, bool clone) 48protected void Initialize(string id, string authenticationType, DateTime effectiveTime, DateTime expirationTime, WindowsIdentity windowsIdentity, bool clone) 74public override DateTime ValidFrom 79public override DateTime ValidTo
System\IdentityModel\Tokens\WindowsUserNameSecurityTokenHandler.cs (1)
104windowsIdentity.AddClaim(new Claim(ClaimTypes.AuthenticationInstant, XmlConvert.ToString(DateTime.UtcNow, DateTimeFormats.Generated), ClaimValueTypes.DateTime));
System\IdentityModel\Tokens\X509SecurityToken.cs (4)
16DateTime effectiveTime = SecurityUtils.MaxUtcDateTime; 17DateTime expirationTime = SecurityUtils.MinUtcDateTime; 79public override DateTime ValidFrom 90public override DateTime ValidTo
System\IdentityModel\Tokens\X509SecurityTokenHandler.cs (1)
586identity.AddClaim(new Claim(ClaimTypes.AuthenticationInstant, XmlConvert.ToString(DateTime.UtcNow, DateTimeFormats.Generated), ClaimValueTypes.DateTime));
System\IdentityModel\WrappedXmlDictionaryReader.cs (1)
415public override DateTime ReadContentAsDateTime()
System\IdentityModel\X509CertificateValidatorEx.cs (1)
79this.chainPolicy.VerificationTime = DateTime.Now;
System\ServiceModel\Security\ISspiNegotiation.cs (1)
15DateTime ExpirationTimeUtc
System\ServiceModel\Security\Tokens\BinarySecretSecurityToken.cs (6)
16DateTime effectiveTime; 53this.effectiveTime = DateTime.UtcNow; 73this.effectiveTime = DateTime.UtcNow; 91public override DateTime ValidFrom 96public override DateTime ValidTo 99get { return DateTime.MaxValue; }
System\ServiceModel\Security\Tokens\BufferedGenericXmlSecurityToken.cs (2)
23DateTime effectiveTime, 24DateTime expirationTime,
System\ServiceModel\Security\Tokens\WrappedKeySecurityToken.cs (5)
19DateTime effectiveTime; 107this.effectiveTime = DateTime.UtcNow; 118public override DateTime ValidFrom 123public override DateTime ValidTo 126get { return DateTime.MaxValue; }
System.IdentityModel.Selectors (21)
infocard\client\System\IdentityModel\Selectors\AsymmetricCryptoHandle.cs (1)
22public AsymmetricCryptoHandle(InternalRefCountedHandle nativeHandle, DateTime expiration, IntPtr parameters)
infocard\client\System\IdentityModel\Selectors\CardSpaceSelector.cs (2)
241DateTime.FromFileTimeUtc(infocardToken.createDate), 242DateTime.FromFileTimeUtc(infocardToken.expiryDate),
infocard\client\System\IdentityModel\Selectors\CryptoHandle.cs (7)
42protected CryptoHandle(InternalRefCountedHandle nativeHandle, DateTime expiration, IntPtr nativeParameters, Type paramType) 71public DateTime Expiration 142DateTime expiration = DateTime.FromFileTimeUtc(hCrypto.expiration); 187DateTime m_expiration; 207public void Initialize(DateTime expiration, object parameters) 231public DateTime Expiration
infocard\client\System\IdentityModel\Selectors\HashCryptoHandle.cs (1)
17public HashCryptoHandle(InternalRefCountedHandle nativeHandle, DateTime expiration, IntPtr parameters)
infocard\client\System\IdentityModel\Selectors\InfoCardProofToken.cs (7)
22DateTime m_expiration; 26public InfoCardProofToken( AsymmetricCryptoHandle cryptoHandle, DateTime expiration ) : this( expiration ) 31public InfoCardProofToken( SymmetricCryptoHandle cryptoHandle, DateTime expiration ) : this( expiration ) 36private InfoCardProofToken( DateTime expiration ) : base() 55public override DateTime ValidTo 60public override DateTime ValidFrom 62get { return DateTime.UtcNow; }
infocard\client\System\IdentityModel\Selectors\ProofTokenCryptoHandle.cs (1)
17protected ProofTokenCryptoHandle(InternalRefCountedHandle nativeHandle, DateTime expiration, IntPtr nativeParameters, Type paramType)
infocard\client\System\IdentityModel\Selectors\SymmetricCryptoHandle.cs (1)
17public SymmetricCryptoHandle(InternalRefCountedHandle nativeHandle, DateTime expiration, IntPtr parameters)
infocard\client\System\IdentityModel\Selectors\TransformCryptoHandle.cs (1)
17public TransformCryptoHandle(InternalRefCountedHandle nativeHandle, DateTime expiration, IntPtr parameters)
System.Management (24)
Instrumentation\SchemaMapping.cs (3)
438 else if(t2 == typeof(DateTime) || t2 == typeof(TimeSpan)) 449 if(t2 == typeof(DateTime) || t2 == typeof(TimeSpan)) 542 else if(t2 == typeof(DateTime))
Instrumentation\WMICapabilities.cs (2)
97wmiCIMOMKey.SetValue(AutoRecoverMofsTimestampVal, DateTime.Now.ToFileTime().ToString((IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(System.Int64)))); 115wmiCIMOMKey.SetValue(AutoRecoverMofsTimestampVal, DateTime.Now.ToFileTime().ToString((IFormatProvider)CultureInfo.InvariantCulture.GetFormat(typeof(System.Int64))));
ManagementDatetime.cs (19)
9 /// <see cref='System.DateTime'/> and <see cref='System.TimeSpan'/> format and vice versa. 85 /// <para>Converts a given DMTF datetime to <see cref='System.DateTime'/> object. The returned DateTime will be in the 90 /// <para>A <see cref='System.DateTime'/> object that represents the given DMTF datetime.</para> 95 /// During conversion to <see cref='System.DateTime'/>, UTC offset is used to convert the date to the 97 /// '*'. This will be converted to the MinValue of this field that can be represented in <see cref='System.DateTime'/>. 110 public static DateTime ToDateTime(string dmtfDate) 112 int year = DateTime.MinValue.Year; 113 int month = DateTime.MinValue.Month; 114 int day = DateTime.MinValue.Day; 115 int hour = DateTime.MinValue.Hour; 116 int minute = DateTime.MinValue.Minute; 117 int second = DateTime.MinValue.Second; 120 DateTime datetime = DateTime.MinValue; 229 /// <para>Converts a given <see cref='System.DateTime'/> object to DMTF format.</para> 232 /// <param name='date'>A <see cref='System.DateTime'/> object representing the datetime to be converted to DMTF datetime.</param> 240 /// in <see cref='System.DateTime'/> is Ticks , which is equivalent to 100 of nanoseconds. 255 public static string ToDmtfDateTime(DateTime date) 294 DateTime dtTemp = new DateTime(date.Year ,date.Month,date.Day ,date.Hour ,date.Minute ,date.Second,0);
System.Messaging (28)
System\Messaging\ActiveXMessageFormatter.cs (2)
323else if (obj is DateTime) 326byte[] bytes = BitConverter.GetBytes(((DateTime)obj).Ticks);
System\Messaging\Message.cs (4)
417public DateTime ArrivedTime 431DateTime time = new DateTime(1970, 1, 1); 1608public DateTime SentTime 1621DateTime time = new DateTime(1970, 1, 1);
System\Messaging\MessageQueue.cs (11)
84private DateTime createTime; 89private DateTime lastModifyTime; 473public DateTime CreateTime 479DateTime time = new DateTime(1970, 1, 1); 786public DateTime LastModifyTime 792DateTime time = new DateTime(1970, 1, 1); 4176entry.timeStamp = System.DateTime.UtcNow; 4212entry.timeStamp = System.DateTime.UtcNow; 4238DateTime now = System.DateTime.UtcNow; 4270public DateTime timeStamp;
System\Messaging\MessageQueueCriteria.cs (11)
28private DateTime createdAfter; 29private DateTime createdBefore; 32private DateTime modifiedAfter; 33private DateTime modifiedBefore; 38private static DateTime minDate = new DateTime(1970, 1, 1); 39private static DateTime maxDate = new DateTime(2038, 1, 19); 47public DateTime CreatedAfter 76public DateTime CreatedBefore 178public DateTime ModifiedAfter 208public DateTime ModifiedBefore 303private int ConvertTime(DateTime time)
System.Runtime.Caching (34)
System\Caching\CacheMemoryMonitor.cs (4)
28private DateTime[] _cacheSizeSampleTimes; 46_cacheSizeSampleTimes = new DateTime[SAMPLE_COUNT]; 154_cacheSizeSampleTimes[_idx] = DateTime.UtcNow; 189internal override int GetPercentToTrim(DateTime lastTrimTime, int lastTrimPercent) {
System\Caching\Dbg.cs (1)
1039static internal string FormatLocalDate(DateTime localTime) {
System\Caching\MemoryCacheEntry.cs (11)
15private DateTime _utcCreated; 18private DateTime _utcAbsExp; 25private DateTime _utcLastUpdateUsage; // time we last updated usage 42return _utcAbsExp < DateTime.MaxValue; 45internal DateTime UtcAbsExp { 50internal DateTime UtcCreated { 87internal DateTime UtcLastUpdateUsage { 103_utcCreated = DateTime.UtcNow; 244internal void UpdateSlidingExp(DateTime utcNow, CacheExpires expires) { 246DateTime utcNewExpires = utcNow + _slidingExp; 268internal void UpdateUsage(DateTime utcNow, CacheUsage usage) {
System\Caching\MemoryCacheEntryChangeMonitor.cs (4)
15private static readonly DateTime DATETIME_MINVALUE_UTC = new DateTime(0, DateTimeKind.Utc); 34DateTime utcCreated = DATETIME_MINVALUE_UTC; 47DateTime utcCreated = DATETIME_MINVALUE_UTC; 71private void StartMonitoring(MemoryCache cache, MemoryCacheEntry entry, ref bool hasChanged, ref DateTime utcCreated) {
System\Caching\MemoryCacheStatistics.cs (3)
28private DateTime _lastTrimTime; 152_lastTrimTime = DateTime.UtcNow; 195_lastTrimTime = DateTime.MinValue;
System\Caching\MemoryCacheStore.cs (7)
52&& (!entry.HasExpiration() || entry.UtcAbsExp - DateTime.UtcNow >= CacheUsage.MIN_LIFETIME_FOR_USAGE)) { 111DateTime utcNow = DateTime.UtcNow; 155if (existingEntry != null && existingEntry.UtcAbsExp <= DateTime.UtcNow) { 196if (entry.UtcAbsExp > DateTime.UtcNow) { 246if (entry != null && entry.UtcAbsExp <= DateTime.UtcNow) { 299if (existingEntry.UtcAbsExp <= DateTime.UtcNow) {
System\Caching\MemoryMonitor.cs (1)
64internal abstract int GetPercentToTrim(DateTime lastTrimTime, int lastTrimPercent);
System\Caching\PhysicalMemoryMonitor.cs (3)
125internal override int GetPercentToTrim(DateTime lastTrimTime, int lastTrimPercent) { 130DateTime utcNow = DateTime.UtcNow;
System.Runtime.Remoting (18)
channels\core\socketcache.cs (8)
169internal void TimeoutSockets(DateTime currentTime) 183private DateTime _socketLastUsed; 190_socketLastUsed = DateTime.UtcNow; 195internal DateTime LastUsed { get { return _socketLastUsed; } } 251TimeSpan socketActiveTime = DateTime.UtcNow - socket.CreationTime; 281internal void TimeoutSockets(DateTime currentTime, TimeSpan socketLifetime) 380DateTime currentTime = DateTime.UtcNow;
channels\core\socketmanager.cs (3)
33private DateTime _creationTime; 65_creationTime = DateTime.UtcNow; 81public DateTime CreationTime { get { return _creationTime; } }
channels\ipc\portcache.cs (6)
23private DateTime _socketLastUsed; 28_socketLastUsed = DateTime.Now; 32internal DateTime LastUsed { get { return _socketLastUsed; } } 67DateTime currentTime = DateTime.UtcNow; 74if (DateTime.Now - connection.LastUsed > _portLifetime)
metadata\sudscommon.cs (1)
120internal static Type typeofDateTime = typeof(DateTime);
System.Runtime.Serialization (104)
System\Runtime\Serialization\DataContract.cs (1)
762type = typeof(DateTime);
System\Runtime\Serialization\DateTimeOffsetAdapter.cs (3)
18DateTime utcDateTime; 21public DateTimeOffsetAdapter(DateTime dateTime, short offsetMinutes) 28public DateTime UtcDateTime
System\Runtime\Serialization\ExtensionDataReader.cs (3)
693DateTime dateTime = isTypedNode ? ((DataNode<DateTime>)dataNode).GetValue() : (DateTime)dataNode.Value;
System\Runtime\Serialization\Json\JsonReaderDelegator.cs (11)
155internal override DateTime ReadContentAsDateTime() 160internal static DateTime ParseJsonDate(string originalDateTimeValue, DateTimeFormat dateTimeFormat) 168return DateTime.ParseExact(originalDateTimeValue, dateTimeFormat.FormatString, dateTimeFormat.FormatProvider, dateTimeFormat.DateTimeStyles); 172internal static DateTime ParseJsonDateInDefaultFormat(string originalDateTimeValue) 234DateTime dateTime = new DateTime(ticks, DateTimeKind.Utc); 240return DateTime.SpecifyKind(dateTime.ToLocalTime(), DateTimeKind.Unspecified); 255internal override DateTime ReadElementContentAsDateTime() 263int arrayLength, out DateTime[] array) 277class DateTimeArrayJsonHelperWithString : ArrayHelper<string, DateTime> 286protected override int ReadArray(XmlDictionaryReader reader, string localName, string namespaceUri, DateTime[] array, int offset, int count) 298protected override void WriteArray(XmlDictionaryWriter writer, string prefix, string localName, string namespaceUri, DateTime[] array, int offset, int count)
System\Runtime\Serialization\Json\JsonWriterDelegator.cs (5)
142internal void WriteJsonDateTimeArray(DateTime[] value, XmlDictionaryString itemName, XmlDictionaryString itemNamespace) 187internal override void WriteDateTime(DateTime value) 199void WriteDateTimeInDefaultFormat(DateTime value) 214if ((tickCount > DateTime.MaxValue.Ticks) || (tickCount < DateTime.MinValue.Ticks))
System\Runtime\Serialization\Json\XmlJsonWriter.cs (5)
364public override void WriteArray(string prefix, string localName, string namespaceUri, DateTime[] array, int offset, int count) 414public override void WriteArray(string prefix, XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count) 1177public override void WriteValue(DateTime value) 1623else if (value is DateTime) 1625WriteValue((DateTime)value);
System\Runtime\Serialization\PrimitiveDataContract.cs (2)
519: base(typeof(DateTime), DictionaryGlobals.DateTimeLocalName, DictionaryGlobals.SchemaNamespace) 528writer.WriteDateTime((DateTime)obj);
System\Runtime\Serialization\XmlReaderDelegator.cs (5)
312return new DataNode<DateTime>(ReadContentAsDateTime()); 517internal virtual DateTime ReadElementContentAsDateTime() 526internal virtual DateTime ReadContentAsDateTime() 879int arrayLength, out DateTime[] array) 890array = new DateTime[arrayLength];
System\Runtime\Serialization\XmlSerializableReader.cs (1)
117public override DateTime ReadContentAsDateTime() { return InnerReader.ReadContentAsDateTime(); }
System\Runtime\Serialization\XmlWriterDelegator.cs (5)
322WriteDateTime((DateTime)value); 399WriteDateTime(((DataNode<DateTime>)dataNode).GetValue()); 460internal virtual void WriteDateTime(DateTime value) 465public void WriteDateTime(DateTime value, XmlDictionaryString name, XmlDictionaryString ns) 691public void WriteDateTimeArray(DateTime[] value, XmlDictionaryString itemName, XmlDictionaryString itemNamespace)
System\Xml\ArrayHelper.cs (6)
311class DateTimeArrayHelperWithString : ArrayHelper<string, DateTime> 315protected override int ReadArray(XmlDictionaryReader reader, string localName, string namespaceUri, DateTime[] array, int offset, int count) 320protected override void WriteArray(XmlDictionaryWriter writer, string prefix, string localName, string namespaceUri, DateTime[] array, int offset, int count) 326class DateTimeArrayHelperWithDictionaryString : ArrayHelper<XmlDictionaryString, DateTime> 330protected override int ReadArray(XmlDictionaryReader reader, XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count) 335protected override void WriteArray(XmlDictionaryWriter writer, string prefix, XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count)
System\Xml\ValueHandle.cs (2)
194return typeof(DateTime); 387public DateTime ToDateTime()
System\Xml\XmlBaseReader.cs (5)
1694public override DateTime ReadContentAsDateTime() 1699DateTime value = node.Value.ToDateTime(); 1817else if (type == typeof(DateTime)) 1977public override DateTime[] ReadDateTimeArray(string localName, string namespaceUri) 1982public override DateTime[] ReadDateTimeArray(XmlDictionaryString localName, XmlDictionaryString namespaceUri)
System\Xml\XmlBaseWriter.cs (3)
1071else if (value is DateTime) 1073WriteValue((DateTime)value); 1241public override void WriteValue(DateTime value)
System\Xml\XmlBinaryReader.cs (6)
250public override DateTime ReadElementContentAsDateTime() 257DateTime value = BufferReader.ReadDateTime(); 1197type = typeof(DateTime); 1460int ReadArray(DateTime[] array, int offset, int count) 1472public override int ReadArray(string localName, string namespaceUri, DateTime[] array, int offset, int count) 1479public override int ReadArray(XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count)
System\Xml\XmlBinaryWriter.cs (5)
836public override void WriteDateTimeText(DateTime dt) 916public void WriteDateTimeArray(DateTime[] array, int offset, int count) 1209else if (type == typeof(DateTime)) 1568public override void WriteArray(string prefix, string localName, string namespaceUri, DateTime[] array, int offset, int count) 1584public override void WriteArray(string prefix, XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count)
System\Xml\XmlBufferReader.cs (2)
485public DateTime ReadDateTime() 491return DateTime.FromBinary(value);
System\Xml\XmlConverter.cs (14)
231static public DateTime ToDateTime(Int64 value) 235return DateTime.FromBinary(value); 243static public DateTime ToDateTime(string value) 259static public DateTime ToDateTime(byte[] buffer, int offset, int count) 261DateTime value; 424static public string ToString(DateTime value) 451else if (value is DateTime) 452return ToString((DateTime)value); 727static bool TryParseDateTime(byte[] chars, int offset, int count, out DateTime result) 730result = DateTime.MaxValue; 814DateTime value; 833if (hourDelta >= 0 && (value < DateTime.MaxValue - ts) || 834hourDelta < 0 && (value > DateTime.MinValue - ts)) 1076static public int ToChars(DateTime value, byte[] chars, int offset)
System\Xml\XmlDictionaryReader.cs (8)
855public override DateTime ReadElementContentAsDateTime() 858DateTime value; 865value = DateTime.Parse(string.Empty, NumberFormatInfo.InvariantInfo); 1263public virtual DateTime[] ReadDateTimeArray(string localName, string namespaceUri) 1268public virtual DateTime[] ReadDateTimeArray(XmlDictionaryString localName, XmlDictionaryString namespaceUri) 1273public virtual int ReadArray(string localName, string namespaceUri, DateTime[] array, int offset, int count) 1285public virtual int ReadArray(XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count) 1694public override DateTime ReadContentAsDateTime()
System\Xml\XmlDictionaryWriter.cs (5)
810else if (type == typeof(DateTime)) 839else if (type == typeof(DateTime)) 1075public virtual void WriteArray(string prefix, string localName, string namespaceUri, DateTime[] array, int offset, int count) 1086public virtual void WriteArray(string prefix, XmlDictionaryString localName, XmlDictionaryString namespaceUri, DateTime[] array, int offset, int count) 1340public override void WriteValue(DateTime value)
System\Xml\XmlMtomReader.cs (1)
813public override DateTime ReadContentAsDateTime()
System\Xml\XmlMtomWriter.cs (2)
366return String.Format(CultureInfo.InvariantCulture, "http://tempuri.org/{0}/{1}", index, DateTime.Now.Ticks); 798public override void WriteValue(DateTime value)
System\Xml\XmlNodeWriter.cs (2)
94public abstract void WriteDateTimeText(DateTime value); 140public override void WriteDateTimeText(DateTime value) { }
System\Xml\XmlSigningNodeWriter.cs (1)
281public override void WriteDateTimeText(DateTime value)
System\Xml\XmlUTF8TextWriter.cs (1)
670public override void WriteDateTimeText(DateTime value)
System.Security (19)
system\security\cryptography\pkcs\pkcs9attribute.cs (6)
68private DateTime m_signingTime; 75public Pkcs9SigningTime() : this(DateTime.Now) {} 77public Pkcs9SigningTime(DateTime signingTime) : base(CAPI.szOID_RSA_signingTime, Encode(signingTime)) { 88public DateTime SigningTime { 120m_signingTime = DateTime.FromFileTimeUtc(signingTime); 125private static byte[] Encode (DateTime signingTime) {
system\security\cryptography\pkcs\pkcsutils.cs (4)
496if (certificate.NotBefore <= DateTime.Now && certificate.NotAfter >= DateTime.Now) { 533if (certificate.HasPrivateKey && certificate.NotBefore <= DateTime.Now && certificate.NotAfter >= DateTime.Now) {
system\security\cryptography\pkcs\recipientinfo.cs (5)
213private DateTime m_date; 271public DateTime Date { 273if (m_date == DateTime.MinValue) { 278m_date = DateTime.FromFileTimeUtc(date); 363m_date = DateTime.MinValue;
system\security\cryptography\pkcs\signerinfo.cs (2)
401DateTime.Now, 692DateTime.Now,
system\security\cryptography\x509\x509utils.cs (2)
299DateTime verificationTime, 369DateTime verificationTime,
System.ServiceModel (293)
System\ServiceModel\Administration\ManagementExtension.cs (7)
16static Dictionary<ServiceHostBase, DateTime> services; 39static Dictionary<ServiceHostBase, DateTime> GetServices() 47ManagementExtension.services = new Dictionary<ServiceHostBase, DateTime>(); 62internal static DateTime GetTimeOpened(ServiceHostBase service) 80Dictionary<ServiceHostBase, DateTime> services = GetServices(); 85services.Add(service, DateTime.Now); 92Dictionary<ServiceHostBase, DateTime> services = GetServices();
System\ServiceModel\Administration\WbemProvider.cs (2)
933if (val is DateTime) 935val = ((DateTime)val).ToString("yyyyMMddhhmmss.ffffff", CultureInfo.InvariantCulture) + "+000";
System\ServiceModel\Channels\ChannelReliableSession.cs (6)
831DateTime start = DateTime.UtcNow; 854void ProcessCreateSequenceResponse(Message response, DateTime start) 933this.InitiationTime = DateTime.UtcNow - start; 1048DateTime start; 1054this.start = DateTime.UtcNow;
System\ServiceModel\Channels\DnsCache.cs (5)
67DateTime now = DateTime.UtcNow; 122DateTime timeStamp; 124public DnsCacheEntry(IPHostEntry hostEntry, DateTime timeStamp) 138public DateTime TimeStamp
System\ServiceModel\Channels\HttpChannelHelpers.cs (2)
2616DateTime modifiedSinceDate; 2617if (DateTime.TryParse(value, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.AllowWhiteSpaces | DateTimeStyles.AssumeLocal, out modifiedSinceDate))
System\ServiceModel\Channels\IdlingCommunicationPool.cs (11)
151this.connectionMapping[connection].LastUsage = DateTime.UtcNow; 161DateTime now = DateTime.UtcNow; 251DateTime now = DateTime.UtcNow; 287bool IdleOutConnection(TItem connection, DateTime now) 358DateTime creationTime; 359DateTime lastUsage; 363this.creationTime = DateTime.UtcNow; 367public DateTime CreationTime 372public DateTime LastUsage
System\ServiceModel\Channels\Msmq4PoisonHandler.cs (2)
294DateTime lastMoveTime = MsmqDateTime.ToDateTime(handler.retryQueueMessage.LastMoveTime.Value); 296TimeSpan waitTime = lastMoveTime + handler.ReceiveParameters.RetryCycleDelay - DateTime.UtcNow;
System\ServiceModel\Channels\MsmqReceiveContext.cs (3)
49DateTime expiryTime; 52public MsmqReceiveContext(long lookupId, DateTime expiryTime, MsmqReceiveContextLockManager manager) 68public DateTime ExpiryTime
System\ServiceModel\Channels\MsmqReceiveContextLockManager.cs (4)
51DateTime expiryTime = TimeoutHelper.Add(DateTime.UtcNow, receiveContextSettings.ValidityDuration); 80if (DateTime.UtcNow > entry.ExpiryTime) 192if (DateTime.UtcNow > msgEntry.Value.ExpiryTime)
System\ServiceModel\Channels\NativeMsmqMessage.cs (1)
583public static DateTime ToDateTime(int seconds)
System\ServiceModel\Channels\PeerSecurityHelpers.cs (6)
332DateTime effectiveTime = DateTime.UtcNow; 333DateTime expirationTime = DateTime.UtcNow.AddHours(10); 363public override DateTime ValidFrom 368public override DateTime ValidTo
System\ServiceModel\Channels\PeerUnsafeNativeCryptMethods.cs (1)
26public SystemTime(DateTime date)
System\ServiceModel\Channels\SelfSignedCertificate.cs (6)
29DateTime.UtcNow, 30DateTime.UtcNow.AddYears(DefaultLifeSpanInYears), 37DateTime start, 38DateTime expire, 49void CreateCertContext(string name, DateTime start, DateTime expire)
System\ServiceModel\Channels\SocketConnection.cs (6)
1718DateTime connectStartTime = DateTime.UtcNow; 1729SocketConnectionInitiator.TraceConnectFailure(socket, socketException, uri, DateTime.UtcNow - connectStartTime); 1788DateTime connectStartTime; 1873this.connectStartTime = DateTime.UtcNow; 1910SocketConnectionInitiator.TraceConnectFailure(this.socket, exception, uri, DateTime.UtcNow - connectStartTime);
System\ServiceModel\Diagnostics\MessageLogTraceRecord.cs (2)
41DateTime timestamp; 49this.timestamp = DateTime.Now;
System\ServiceModel\Diagnostics\TraceUtility.cs (1)
534TimeSpan elapsedTime = new TimeSpan(DateTime.UtcNow.Ticks - startTicks);
System\ServiceModel\Dispatcher\AsyncMethodInvoker.cs (1)
265TraceUtility.UpdateAsyncOperationContextWithStartTime(eventTraceActivity, DateTime.UtcNow.Ticks);
System\ServiceModel\Dispatcher\PrimitiveOperationFormatter.cs (4)
741value = new DateTime[0]; 867DateTime[] arrayValue = (DateTime[])value; 913writer.WriteValue((DateTime)value);
System\ServiceModel\Dispatcher\SecurityImpersonationBehavior.cs (1)
431this.random = new Random(unchecked((int)DateTime.Now.Ticks));
System\ServiceModel\Dispatcher\SyncMethodInvoker.cs (1)
126beginOperation = DateTime.UtcNow.Ticks;
System\ServiceModel\Dispatcher\TransactedBatchContext.cs (5)
17DateTime commitNotLaterThan; 28this.commitNotLaterThan = DateTime.MaxValue; 30this.commitNotLaterThan = DateTime.UtcNow + TimeSpan.FromMilliseconds(shared.TransactionTimeout.TotalMilliseconds * 4 / 5); 40return DateTime.UtcNow > this.commitNotLaterThan; 125if (this.commits >= this.shared.CurrentBatchSize || DateTime.UtcNow >= this.commitNotLaterThan)
System\ServiceModel\Dispatcher\XPathMessageContext.cs (5)
204internal readonly static DateTime ZeroDate = new DateTime(1, 1, 1, 0, 0, 0, DateTimeKind.Utc); 414internal static double ConvertDate(DateTime date) 1586return ConvertDate(DateTime.Parse(dateStr, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.RoundtripKind)); 1664context.Push(ConvertDate(DateTime.Now), count); 1670return ConvertDate(DateTime.UtcNow);
System\ServiceModel\MsmqIntegration\ActiveXSerializer.cs (2)
315else if (obj is DateTime) 317byte[] bytes = BitConverter.GetBytes(((DateTime)obj).Ticks);
System\ServiceModel\MsmqIntegration\MsmqIntegrationMessageProperty.cs (4)
59DateTime? arrivedTime = null; 60public DateTime? ArrivedTime 147DateTime? sentTime = null; 148public DateTime? SentTime
System\ServiceModel\MsmqIntegration\MsmqMessage.cs (2)
61public DateTime? ArrivedTime 127public DateTime? SentTime
System\ServiceModel\PeerResolvers\CustomPeerResolverService.cs (8)
28DateTime expires; 33public RegistrationEntry(Guid clientId, Guid registrationId, string meshId, DateTime expires, PeerNodeAddress address) 61public DateTime Expires 321DateTime expiry = DateTime.UtcNow + RefreshInterval; 417entry.Expires = DateTime.UtcNow + this.RefreshInterval; 553entry.Expires = DateTime.UtcNow + RefreshInterval; 650if ((item.Value.Expires <= DateTime.UtcNow) || (item.Value.State == RegistrationState.Deleted))
System\ServiceModel\Security\AcceleratedTokenAuthenticator.cs (3)
222DateTime effectiveTime = DateTime.UtcNow; 223DateTime expirationTime = TimeoutHelper.Add(effectiveTime, this.ServiceTokenLifetime);
System\ServiceModel\Security\IdentityModelServiceAuthorizationManager.cs (3)
238AddAuthenticationInstantClaim(claimsIdentity, XmlConvert.ToString(DateTime.UtcNow, DateTimeFormats.Generated)); 528AddAuthenticationInstantClaim(claimsIdentity, XmlConvert.ToString(DateTime.UtcNow, DateTimeFormats.Generated)); 533AddAuthenticationInstantClaim(claimsIdentity, XmlConvert.ToString(DateTime.UtcNow, DateTimeFormats.Generated));
System\ServiceModel\Security\InfoCardHelper.cs (1)
597if (m_infocardChannelParameter.Token.ValidTo < DateTime.UtcNow)
System\ServiceModel\Security\InMemoryNonceCache.cs (2)
71DateTime expirationTime = TimeoutHelper.Add(DateTime.UtcNow, this.cachingTimeSpan);
System\ServiceModel\Security\IssuanceTokenProviderBase.cs (5)
303DateTime GetServiceTokenEffectiveExpirationTime(SecurityToken serviceToken) 315DateTime effectiveExpirationTime = TimeoutHelper.Add(serviceToken.ValidFrom.ToUniversalTime(), new TimeSpan(effectiveTicksInterval)); 316DateTime maxCachingTime = TimeoutHelper.Add(serviceToken.ValidFrom.ToUniversalTime(), this.MaxServiceTokenCachingTime); 329DateTime effectiveExpirationTime = GetServiceTokenEffectiveExpirationTime(serviceToken); 330return (DateTime.UtcNow <= effectiveExpirationTime);
System\ServiceModel\Security\NegotiationTokenAuthenticator.cs (6)
416DateTime tokenEffectiveTime, DateTime tokenExpirationTime, 424DateTime tokenEffectiveTime, DateTime tokenExpirationTime, UniqueId keyGeneration, DateTime keyEffectiveTime, 425DateTime keyExpirationTime, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies, bool isCookieMode)
System\ServiceModel\Security\NegotiationTokenAuthenticatorStateCache.cs (2)
28DateTime expirationTime = TimeoutHelper.Add(DateTime.UtcNow, this.cachingSpan);
System\ServiceModel\Security\RequestSecurityTokenResponse.cs (12)
47DateTime effectiveTime; 48DateTime expirationTime; 79DateTime validFrom, 80DateTime validTo, 106DateTime validFrom, 107DateTime validTo, 148DateTime validFrom, 149DateTime validTo, 233public DateTime ValidFrom 241public DateTime ValidTo 492public void SetLifetime(DateTime validFrom, DateTime validTo)
System\ServiceModel\Security\SecurityContextTokenCache.cs (1)
188public void UpdateContextCachingTime(SecurityContextSecurityToken token, DateTime expirationTime)
System\ServiceModel\Security\SecuritySessionClientSettings.cs (9)
422DateTime keyRenewalTime; 423DateTime keyRolloverTime; 921this.keyRenewalTime = DateTime.UtcNow; 1168if (DateTime.UtcNow >= this.keyRolloverTime && this.previousSessionToken != null) 1179DateTime GetKeyRenewalTime(SecurityToken token) 1182DateTime keyRenewalTime1 = TimeoutHelper.Add(token.ValidFrom, tokenValidityInterval); 1183DateTime keyRenewalTime2 = TimeoutHelper.Add(token.ValidFrom, this.settings.keyRenewalInterval); 1200return DateTime.UtcNow >= this.keyRenewalTime; 1212this.keyRolloverTime = TimeoutHelper.Add(DateTime.UtcNow, this.Settings.KeyRolloverInterval);
System\ServiceModel\Security\SecuritySessionSecurityTokenAuthenticator.cs (11)
587DateTime GetKeyExpirationTime(SecurityToken currentToken, DateTime keyEffectiveTime) 589DateTime keyExpirationTime = TimeoutHelper.Add(keyEffectiveTime, this.keyRenewalInterval); 590DateTime tokenExpirationTime = (currentToken != null) ? currentToken.ValidTo : TimeoutHelper.Add(keyEffectiveTime, this.sessionTokenLifetime); 598internal static ReadOnlyCollection<IAuthorizationPolicy> CreateSecureConversationPolicies(SecurityMessageProperty security, DateTime expirationTime) 603static ReadOnlyCollection<IAuthorizationPolicy> CreateSecureConversationPolicies(SecurityMessageProperty security, ReadOnlyCollection<IAuthorizationPolicy> currentTokenPolicies, DateTime expirationTime) 696DateTime keyEffectiveTime = DateTime.UtcNow; 697DateTime keyExpirationTime = GetKeyExpirationTime(currentToken, keyEffectiveTime); 709DateTime tokenEffectiveTime = keyEffectiveTime; 710DateTime tokenExpirationTime = TimeoutHelper.Add(tokenEffectiveTime, this.sessionTokenLifetime);
System\ServiceModel\Security\SecuritySessionServerSettings.cs (4)
1400if (incomingToken.KeyExpirationTime < DateTime.UtcNow && 1425DateTime keyRolloverTime = TimeoutHelper.Add(DateTime.UtcNow, this.settings.KeyRolloverInterval); 1825if (this.currentSessionToken.KeyExpirationTime < DateTime.UtcNow)
System\ServiceModel\Security\SecurityTimestamp.cs (11)
19DateTime creationTimeUtc; 20DateTime expiryTimeUtc; 25public SecurityTimestamp(DateTime creationTimeUtc, DateTime expiryTimeUtc, string id) 30internal SecurityTimestamp(DateTime creationTimeUtc, DateTime expiryTimeUtc, string id, string digestAlgorithm, byte[] digest) 48public DateTime CreationTimeUtc 56public DateTime ExpiryTimeUtc 103static char[] ToChars(ref DateTime utcTime) 173DateTime now = DateTime.UtcNow;
System\ServiceModel\Security\SecurityUtils.cs (12)
326internal static bool IsCurrentlyTimeEffective(DateTime effectiveTime, DateTime expirationTime, TimeSpan maxClockSkew) 328DateTime curEffectiveTime = (effectiveTime < DateTime.MinValue.Add(maxClockSkew)) ? effectiveTime : effectiveTime.Subtract(maxClockSkew); 329DateTime curExpirationTime = (expirationTime > DateTime.MaxValue.Subtract(maxClockSkew)) ? expirationTime : expirationTime.Add(maxClockSkew); 330DateTime curTime = DateTime.UtcNow; 369public static DateTime MaxUtcDateTime 374return new DateTime(DateTime.MaxValue.Ticks - TimeSpan.TicksPerDay, DateTimeKind.Utc); 378public static DateTime MinUtcDateTime 383return new DateTime(DateTime.MinValue.Ticks + TimeSpan.TicksPerDay, DateTimeKind.Utc);
System\ServiceModel\Security\SendSecurityHeader.cs (2)
361DateTime now = DateTime.UtcNow;
System\ServiceModel\Security\SpnegoTokenAuthenticator.cs (1)
141policies.Add(new System.IdentityModel.Policy.UnconditionalPolicy(wic, TimeoutHelper.Add(DateTime.UtcNow, base.ServiceTokenLifetime)));
System\ServiceModel\Security\SspiNegotiationTokenAuthenticator.cs (3)
91DateTime effectiveTime = DateTime.UtcNow; 92DateTime expirationTime = TimeoutHelper.Add(effectiveTime, this.ServiceTokenLifetime);
System\ServiceModel\Security\TimeBoundedCache.cs (13)
24DateTime nextPurgeTimeUtc; 39this.nextPurgeTimeUtc = DateTime.UtcNow.Add(this.purgeInterval); 86protected bool TryAddItem(object key, object item, DateTime expirationTime, bool replaceExistingEntry) 155protected bool TryReplaceItem(object key, object item, DateTime expirationTime) 348Fx.Assert(item.ExpirationTime == DateTime.MaxValue || item.ExpirationTime.Kind == DateTimeKind.Utc, ""); 349return (item.ExpirationTime <= DateTime.UtcNow); 358else if (this.purgingMode == PurgingMode.AccessBasedPurge && DateTime.UtcNow > this.nextPurgeTimeUtc && this.Count > this.lowWaterMark) 409this.nextPurgeTimeUtc = DateTime.UtcNow.Add(this.purgeInterval); 454DateTime ExpirationTime { get; } 498DateTime expirationTime; 501public ExpirableItem(object item, DateTime expirationTime) 504Fx.Assert( expirationTime == DateTime.MaxValue || expirationTime.Kind == DateTimeKind.Utc, ""); 508public DateTime ExpirationTime { get { return this.expirationTime; } }
System\ServiceModel\Security\TlsSspiNegotiation.cs (1)
160public DateTime ExpirationTimeUtc
System\ServiceModel\Security\Tokens\DerivedKeySecurityToken.cs (2)
93public override DateTime ValidFrom 98public override DateTime ValidTo
System\ServiceModel\Security\Tokens\DerivedKeySecurityTokenStub.cs (2)
43public override DateTime ValidFrom 49public override DateTime ValidTo
System\ServiceModel\Security\Tokens\ISecurityContextSecurityTokenCache.cs (1)
19void UpdateContextCachingTime(SecurityContextSecurityToken context, DateTime expirationTime);
System\ServiceModel\Security\Tokens\ProviderBackedSecurityToken.cs (2)
129public override DateTime ValidFrom 142public override DateTime ValidTo
System\ServiceModel\Security\Tokens\SecurityContextCookieSerializer.cs (10)
41DateTime effectiveTime = SecurityUtils.MinUtcDateTime; 42DateTime expiryTime = SecurityUtils.MaxUtcDateTime; 46DateTime keyEffectiveTime = SecurityUtils.MinUtcDateTime; 47DateTime keyExpirationTime = SecurityUtils.MaxUtcDateTime; 150public byte[] CreateCookieFromSecurityContext(UniqueId contextId, string id, byte[] key, DateTime tokenEffectiveTime, 151DateTime tokenExpirationTime, UniqueId keyGeneration, DateTime keyEffectiveTime, DateTime keyExpirationTime, 261DateTime expirationTime; 263public SctUnconditionalPolicy(IList<IIdentity> identities, IList<ClaimSet> claimSets, DateTime expirationTime)
System\ServiceModel\Security\Tokens\SecurityContextSecurityToken.cs (39)
20DateTime keyEffectiveTime; 21DateTime keyExpirationTime; 22DateTime tokenEffectiveTime; 23DateTime tokenExpirationTime; 33public SecurityContextSecurityToken(UniqueId contextId, byte[] key, DateTime validFrom, DateTime validTo) 37public SecurityContextSecurityToken(UniqueId contextId, string id, byte[] key, DateTime validFrom, DateTime validTo) 41public SecurityContextSecurityToken(UniqueId contextId, string id, byte[] key, DateTime validFrom, DateTime validTo, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies) 48public SecurityContextSecurityToken(UniqueId contextId, string id, byte[] key, DateTime validFrom, DateTime validTo, UniqueId keyGeneration, DateTime keyEffectiveTime, DateTime keyExpirationTime, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies) 60internal SecurityContextSecurityToken(SecurityContextSecurityToken sourceToken, string id, byte[] key, UniqueId keyGeneration, DateTime keyEffectiveTime, DateTime keyExpirationTime, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies) 69internal SecurityContextSecurityToken(UniqueId contextId, string id, byte[] key, DateTime validFrom, DateTime validTo, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies, bool isCookieMode, byte[] cookieBlob) 74internal SecurityContextSecurityToken(UniqueId contextId, string id, byte[] key, DateTime validFrom, DateTime validTo, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies, bool isCookieMode, byte[] cookieBlob, 75UniqueId keyGeneration, DateTime keyEffectiveTime, DateTime keyExpirationTime) 139public DateTime KeyEffectiveTime 147public DateTime KeyExpirationTime 177public override DateTime ValidFrom 182public override DateTime ValidTo 209DateTime TimeBoundedCache.IExpirableItem.ExpirationTime 238void Initialize(UniqueId contextId, byte[] key, DateTime validFrom, DateTime validTo, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies, bool isCookieMode, 239UniqueId keyGeneration, DateTime keyEffectiveTime, DateTime keyExpirationTime) 251DateTime tokenEffectiveTimeUtc = validFrom.ToUniversalTime(); 252DateTime tokenExpirationTimeUtc = validTo.ToUniversalTime(); 308DateTime validFrom, DateTime validTo, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies, SecurityStateEncoder securityStateEncoder) 315DateTime validFrom, DateTime validTo, UniqueId keyGeneration, DateTime keyEffectiveTime, 316DateTime keyExpirationTime, ReadOnlyCollection<IAuthorizationPolicy> authorizationPolicies, SecurityStateEncoder securityStateEncoder)
System\ServiceModel\Security\Tokens\SecurityContextSecurityTokenAuthenticator.cs (2)
44DateTime utcNow = DateTime.UtcNow;
System\ServiceModel\Security\Tokens\SecurityContextSecurityTokenResolver.cs (1)
102public void UpdateContextCachingTime(SecurityContextSecurityToken context, DateTime expirationTime)
System\ServiceModel\Security\Tokens\SspiSecurityToken.cs (6)
23DateTime effectiveTime; 24DateTime expirationTime; 31this.effectiveTime = DateTime.UtcNow; 40this.effectiveTime = DateTime.UtcNow; 54public override DateTime ValidFrom 59public override DateTime ValidTo
System\ServiceModel\Security\Tokens\WindowsUserNameCachingSecurityTokenAuthenticator.cs (2)
48DateTime expirationTime = DateTime.UtcNow.Add(this.cachedLogonTokenLifetime);
System\ServiceModel\Security\WindowsSspiNegotiation.cs (1)
87public DateTime ExpirationTimeUtc
System\ServiceModel\Security\WrappedTokenCache.cs (4)
59DateTime expiryTime = DateTimeUtil.Add(sessionToken.ValidTo, _claimsHandler.SecurityTokenHandlerCollection.Configuration.MaxClockSkew); 140DateTime expiryTime = DateTimeUtil.Add(token.ValidTo, _claimsHandler.SecurityTokenHandlerCollection.Configuration.MaxClockSkew); 145public void UpdateContextCachingTime(SecurityContextSecurityToken token, DateTime expirationTime) 154DateTime expiryTime = DateTimeUtil.Add(sessionToken.ValidTo, _claimsHandler.SecurityTokenHandlerCollection.Configuration.MaxClockSkew);
System\ServiceModel\Security\WSTrust.cs (11)
344DateTime created = DateTime.UtcNow; 345DateTime expires = SecurityUtils.MaxUtcDateTime; 383created = DateTime.ParseExact(XmlHelper.ReadTextElementAsTrimmedString(createdXml), 389expires = DateTime.ParseExact(XmlHelper.ReadTextElementAsTrimmedString(expiresXml), 683DateTime created = rstr.ValidFrom; 684DateTime expires = rstr.ValidTo; 792DateTime created = rstr.ValidFrom; 793DateTime expires = rstr.ValidTo; 1184DateTime effectiveTime = SecurityUtils.MinUtcDateTime; 1185DateTime expirationTime = SecurityUtils.MaxUtcDateTime;
System\ServiceModel\Security\WSTrustChannel.cs (6)
492DateTime? created = null; 493DateTime? expires = null; 502created = DateTime.UtcNow; 506expires = DateTime.UtcNow.AddHours(10); 511created = DateTime.UtcNow; 512expires = DateTime.UtcNow.AddHours(10);
System\ServiceModel\Security\WSUtilitySpecificationVersion.cs (2)
101DateTime creationTimeUtc = reader.ReadContentAsDateTime().ToUniversalTime(); 104DateTime expiryTimeUtc;
System\ServiceModel\Security\X509ClientCertificateAuthentication.cs (2)
255chain.ChainPolicy.VerificationTime = DateTime.Now; 267chain.ChainPolicy.VerificationTime = DateTime.Now;
System.ServiceModel.Activation (4)
System\ServiceModel\ServiceHostingEnvironment.cs (4)
47static DateTime insufficientMemoryLogStartInterval = DateTime.MinValue; 201DateTime now = DateTime.UtcNow;
System.ServiceModel.Activities (2)
System\ServiceModel\Activities\Dispatcher\WorkflowServiceInstance.cs (1)
1524data[WorkflowNamespace.LastUpdate] = new InstanceValue(DateTime.UtcNow, InstanceValueOptions.WriteOnly | InstanceValueOptions.Optional);
System\ServiceModel\Activities\WorkflowOperationContext.cs (1)
460this.beginOperation = DateTime.UtcNow.Ticks;
System.ServiceModel.Discovery (6)
System\ServiceModel\Discovery\AsyncOperationContext.cs (3)
21Nullable<DateTime> startTime; 110public Nullable<DateTime> StartedAt 129this.startTime = DateTime.UtcNow;
System\ServiceModel\Discovery\DiscoveryClient.cs (1)
1362TimeSpan elaspedTime = DateTime.UtcNow.Subtract(StartedAt.Value);
System\ServiceModel\Discovery\DiscoveryMessageSequenceGenerator.cs (2)
12static readonly DateTime DT1970 = new DateTime(1970, 1, 1); 38return (long)DateTime.Now.Subtract(DT1970).TotalSeconds;
System.ServiceModel.Internals (33)
System\Runtime\BackoffTimeoutHelper.cs (7)
17DateTime deadline; 56this.deadline = DateTime.MaxValue; 60this.deadline = DateTime.UtcNow + timeout; 67if (this.deadline == DateTime.MaxValue) 73return (DateTime.UtcNow >= this.deadline); 120if (this.deadline != DateTime.MaxValue) 122TimeSpan remainingTime = this.deadline - DateTime.UtcNow;
System\Runtime\Collections\ObjectCache.cs (9)
139cacheItem.CreationTime = DateTime.UtcNow; 160DateTime now = DateTime.UtcNow; 212bool ShouldPurgeItem(Item cacheItem, DateTime now) 246DateTime now = DateTime.UtcNow; 366public DateTime CreationTime 372public DateTime LastUsage 396else if (this.referenceCount == 0 && this.parent.ShouldPurgeItem(this, DateTime.UtcNow))
System\Runtime\Diagnostics\DiagnosticTraceBase.cs (4)
44this.LastFailure = DateTime.MinValue; 47protected DateTime LastFailure { get; set; } 446if (DateTime.UtcNow.Subtract(this.LastFailure) >= FailureBlackout) 448this.LastFailure = DateTime.UtcNow;
System\Runtime\TimeoutHelper.cs (13)
12DateTime deadline; 22this.deadline = DateTime.MaxValue; 82public static DateTime Add(DateTime time, TimeSpan timeout) 84if (timeout >= TimeSpan.Zero && DateTime.MaxValue - time <= timeout) 86return DateTime.MaxValue; 88if (timeout <= TimeSpan.Zero && DateTime.MinValue - time >= timeout) 90return DateTime.MinValue; 95public static DateTime Subtract(DateTime time, TimeSpan timeout) 117else if (this.deadline == DateTime.MaxValue) 123TimeSpan remaining = this.deadline - DateTime.UtcNow; 143this.deadline = DateTime.UtcNow + this.originalTimeout;
System.ServiceModel.Web (26)
System\ServiceModel\Description\WebScriptClientGenerator.cs (4)
23DateTime serviceLastModified; 34this.serviceLastModified = DateTime.UtcNow; 115DateTime ifModifiedSinceDateTime; 116if (DateTime.TryParse(ifModifiedSinceHeaderValue, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.AdjustToUniversal, out ifModifiedSinceDateTime))
System\ServiceModel\Dispatcher\HelpExampleGenerator.cs (4)
357DateTime dateTime = DateTime.Parse("1999-05-31T11:20:00", CultureInfo.InvariantCulture); 507DateTime dateTime = DateTime.Parse("1999-05-31T11:20:00", CultureInfo.InvariantCulture);
System\ServiceModel\Dispatcher\HelpPage.cs (3)
32DateTime startupTime = DateTime.UtcNow; 119if (((DateTime)state) == this.startupTime)
System\ServiceModel\Dispatcher\QueryStringConverter.cs (4)
45this.defaultSupportedQueryStringTypes.Add(typeof(DateTime), null); 115return parameter == null ? default(DateTime) : DateTime.Parse(parameter, CultureInfo.InvariantCulture, DateTimeStyles.RoundtripKind); 214return XmlConvert.ToString((DateTime) parameter, XmlDateTimeSerializationMode.RoundtripKind);
System\ServiceModel\Web\HttpDateParse.cs (1)
247internal static bool ParseHttpDate(String DateString, out DateTime dtOut)
System\ServiceModel\Web\IncomingWebRequestContext.cs (6)
71public DateTime? IfModifiedSince 78DateTime parsedDateTime; 88public DateTime? IfUnmodifiedSince 95DateTime parsedDateTime; 179public void CheckConditionalRetrieve(DateTime lastModified) 188DateTime? ifModifiedSince = this.IfModifiedSince;
System\ServiceModel\Web\OutgoingWebResponseContext.cs (4)
55public DateTime LastModified 62DateTime parsedDateTime; 63if (DateTime.TryParse(dateTime, CultureInfo.InvariantCulture, DateTimeStyles.None, out parsedDateTime)) 68return DateTime.MinValue;
System.Transactions (7)
System\Transactions\Oletx\OleTxTransaction.cs (3)
589private DateTime creationTime; 590private DateTime lastStateChangeTime; 769this.creationTime = DateTime.UtcNow;
System\Transactions\TransactionInformation.cs (1)
85public DateTime CreationTime
System\Transactions\TransactionTable.cs (3)
229return DateTime.UtcNow.Ticks; 262this.lastTimerTime = DateTime.UtcNow.Ticks; 426this.lastTimerTime = DateTime.UtcNow.Ticks;
System.Web (766)
Abstractions\HttpCachePolicyBase.cs (2)
65public virtual void SetExpires(DateTime date) { 71public virtual void SetLastModified(DateTime date) {
Abstractions\HttpCachePolicyWrapper.cs (2)
67public override void SetExpires(DateTime date) { 71public override void SetLastModified(DateTime date) {
Abstractions\HttpContextBase.cs (1)
197public virtual DateTime Timestamp {
Abstractions\HttpContextWrapper.cs (1)
203public override DateTime Timestamp {
Abstractions\HttpResponseBase.cs (1)
105public virtual DateTime ExpiresAbsolute {
Abstractions\HttpResponseWrapper.cs (1)
111public override DateTime ExpiresAbsolute {
Cache\cache.cs (12)
49out object expensiveObject, out CacheDependency dependency, out DateTime absoluteExpiration, out TimeSpan slidingExpiration); 174public static readonly DateTime NoAbsoluteExpiration = DateTime.MaxValue; 365DateTime absoluteExpiration; 421public void Insert(string key, object value, CacheDependency dependencies, DateTime absoluteExpiration, TimeSpan slidingExpiration) { 422DateTime utcAbsoluteExpiration = DateTimeUtil.ConvertToUniversalTime(absoluteExpiration); 434DateTime absoluteExpiration, 439DateTime utcAbsoluteExpiration = DateTimeUtil.ConvertToUniversalTime(absoluteExpiration); 455DateTime absoluteExpiration, 465DateTime utcAbsoluteExpiration = DateTimeUtil.ConvertToUniversalTime(absoluteExpiration); 498DateTime absoluteExpiration, 503DateTime utcAbsoluteExpiration = DateTimeUtil.ConvertToUniversalTime(absoluteExpiration);
Cache\CacheDependency.cs (37)
51DateTime _utcLastModified; // Time of last modified item 97Init(true, null, null, null, DateTime.MaxValue); 106this (filename, DateTime.MaxValue) { 110public CacheDependency(string filename, DateTime start) { 115DateTime utcStart = DateTimeUtil.ConvertToUniversalTime(start); 127Init(true, filenames, null, null, DateTime.MaxValue); 131public CacheDependency(string[] filenames, DateTime start) { 132DateTime utcStart = DateTimeUtil.ConvertToUniversalTime(start); 142Init(true, filenames, cachekeys, null, DateTime.MaxValue); 146public CacheDependency(string[] filenames, string[] cachekeys, DateTime start) { 147DateTime utcStart = DateTimeUtil.ConvertToUniversalTime(start); 153Init(true, filenames, cachekeys, dependency, DateTime.MaxValue); 157public CacheDependency(string[] filenames, string[] cachekeys, CacheDependency dependency, DateTime start) { 158DateTime utcStart = DateTimeUtil.ConvertToUniversalTime(start); 163this(dummy, filename, DateTime.MaxValue) { 166internal CacheDependency(int dummy, string filename, DateTime utcStart) { 177Init(false, filenames, null, null, DateTime.MaxValue); 180internal CacheDependency(int dummy, string[] filenames, DateTime utcStart) { 185Init(false, filenames, cachekeys, null, DateTime.MaxValue); 188internal CacheDependency(int dummy, string[] filenames, string[] cachekeys, DateTime utcStart) { 193Init(false, filenames, cachekeys, dependency, DateTime.MaxValue); 196internal CacheDependency(int dummy, string[] filenames, string[] cachekeys, CacheDependency dependency, DateTime utcStart) { 304void Init(bool isPublic, string[] filenamesArg, string[] cachekeysArg, CacheDependency dependency, DateTime utcStart) { 333_utcLastModified = DateTime.MinValue; 379DateTime d_lastModified = dependency._utcLastModified; 469DateTime utcNow = DateTime.MinValue; 471DateTime utcLastWrite = fmon.StartMonitoringPath(f, handler, out myDepFileInfos[i]._fad); 480if (utcStart < DateTime.MaxValue) { 481if (utcNow == DateTime.MinValue) { 482utcNow = DateTime.UtcNow; 505DateTime lastUpdated; 697public DateTime UtcLastModified { 703protected void SetUtcLastModified(DateTime utcLastModified) { 826_utcLastModified = DateTime.UtcNow; 960DateTime utcLastModified = DateTime.MinValue;
Cache\CacheEntry.cs (9)
104DateTime _utcCreated; /* creation date */ 108DateTime _utcExpires; /* when this item expires */ 116DateTime _utcLastUpdate; /* time we last updated usage */ 132DateTime utcAbsoluteExpiration, 160_utcCreated = DateTime.UtcNow; 187internal DateTime UtcCreated { 196internal DateTime UtcExpires { 216return _utcExpires < DateTime.MaxValue; 232internal DateTime UtcLastUsageUpdate {
Cache\OutputCache.cs (2)
656DateTime absExp, TimeSpan slidingExp, 768DateTime absExp, TimeSpan slidingExp) {
Cache\OutputCacheProvider.cs (2)
12public abstract Object Add(String key, Object entry, DateTime utcExpiry); 14public abstract void Set(String key, Object entry, DateTime utcExpiry);
Cache\SqlCacheDependency.cs (14)
482internal DateTime _utcTablesUpdated; // Time when _tables was last updated 503_utcTablesUpdated = DateTime.MinValue; 630DateTime waitLimit = DateTime.UtcNow.AddMilliseconds(waitTimeoutMs); 655if (!System.Diagnostics.Debugger.IsAttached && DateTime.UtcNow > waitLimit) { 800DateTime waitLimit = DateTime.UtcNow.Add(new TimeSpan(0, 0, timeout)); 814if (!System.Diagnostics.Debugger.IsAttached && DateTime.UtcNow > waitLimit) { 969dbState._utcTablesUpdated = DateTime.UtcNow; 1020DateTime waitLimit = DateTime.UtcNow.Add(new TimeSpan(0, 0, timeout)); 1031if (!System.Diagnostics.Debugger.IsAttached && DateTime.UtcNow > waitLimit) { 1042DateTime utcTablesLastUpdated; 1085DateTime.UtcNow - utcTablesLastUpdated >= OneSec) {
CachedPathData.cs (1)
377AbsoluteExpiration = DateTime.UtcNow.AddSeconds(5),
Compilation\ApplicationBuildProvider.cs (2)
45DateTime utcStart = DateTime.UtcNow;
Compilation\BrowserCapabilitiesCompiler.cs (2)
106DateTime utcStart = DateTime.UtcNow;
Compilation\BuildManager.cs (7)
1697DateTime utcStart = DateTime.UtcNow; 2362_caches[j].CacheBuildResult(cacheKey, result, DateTime.UtcNow); 2401BuildResult result, DateTime utcStart) { 2407BuildResult result, DateTime utcStart) { 2413internal static bool CacheBuildResult(string cacheKey, BuildResult result, DateTime utcStart) { 2418long hashCode, DateTime utcStart) {
Compilation\BuildManagerHost.cs (3)
421DateTime utcStart = DateTime.UtcNow; 635IEnumerable virtualPathDependencies, DateTime utcStart) {
Compilation\BuildProvidersCompiler.cs (2)
260private DateTime _utcStart; 286_utcStart = DateTime.UtcNow;
Compilation\BuildResult.cs (8)
125ret._nextUpToDateCheck = DateTime.MinValue; 201private DateTime _nextUpToDateCheck = DateTime.Now.AddSeconds(UpdateInterval); 251internal virtual DateTime MemoryCacheExpiration { 344DateTime now = DateTime.Now; 405internal override DateTime MemoryCacheExpiration { 410return DateTime.UtcNow.AddSeconds(10);
Compilation\BuildResultCache.cs (6)
44internal void CacheBuildResult(string cacheKey, BuildResult result, DateTime utcStart) { 49long hashCode, DateTime utcStart); 152long hashCode, DateTime utcStart) { 443long hashCode, DateTime utcStart) { 981long hashCode, DateTime utcStart) { 1002long hashCode, DateTime utcStart) {
Compilation\CodeDirectoryCompiler.cs (5)
139DateTime utcStart = DateTime.UtcNow; 178DateTime waitLimit = DateTime.UtcNow.AddMilliseconds(3000); 189if (DateTime.UtcNow > waitLimit) {
Compilation\ThemeDirectoryCompiler.cs (2)
104DateTime utcStart = DateTime.UtcNow;
Compilation\TimeStampChecker.cs (8)
42DateTime lastWriteTimeUtc = File.GetLastWriteTimeUtc(path); 45DateTime storedValue = (DateTime)_timeStamps[virtualPath]; 48if (storedValue == DateTime.MaxValue) { 55_timeStamps[virtualPath] = DateTime.MaxValue; 83DateTime lastWriteTimeUtc = File.GetLastWriteTimeUtc(path); 84DateTime storedValue = (DateTime)_timeStamps[virtualPath];
Configuration\FileDetails.cs (4)
28DateTime _utcCreationTime; 29DateTime _utcLastWriteTime; 31internal FileDetails(bool exists, long fileSize, DateTime utcCreationTime, DateTime utcLastWriteTime) {
Configuration\RemoteWebConfigurationHost.cs (2)
241return new FileDetails(exists, size, DateTime.FromFileTimeUtc(createDate), DateTime.FromFileTimeUtc(lastWriteDate));
Configuration\RemoteWebConfigurationHostServer.cs (6)
55DateTime lastWrite = File.GetLastWriteTimeUtc(fileName); 56readTime = (DateTime.UtcNow > lastWrite ? DateTime.UtcNow.Ticks : lastWrite.Ticks); 59readTime = DateTime.UtcNow.Ticks; 152utcNowTicks = DateTime.UtcNow.Ticks; 272DateTime creationTime;
FileChangesMonitor.cs (18)
54internal readonly DateTime UtcStartMonitoring;// time we started monitoring 60UtcStartMonitoring = DateTime.UtcNow; 226DateTime _utcLastCompletion; // date of the last RDCW completion 251internal DateTime UtcLastCompletion { 496DateTime utcCompletion; 498utcCompletion = DateTime.MinValue; 878bool IsChangeAfterStartMonitoring(FileAttributesData fad, FileMonitorTarget target, DateTime utcCompletion) { 973internal void OnFileChange(FileAction action, string fileName, DateTime utcCompletion) { 990DateTime utcLastCompletion = DateTime.MinValue; 1670internal DateTime StartMonitoringFile(string alias, FileChangeEventHandler callback) { 1690return DateTime.MinValue; 1699return DateTime.MinValue; 1754return DateTime.MinValue; 1763internal DateTime StartMonitoringPath(string alias, FileChangeEventHandler callback, out FileAttributesData fad) { 1786return DateTime.MinValue; 1794return DateTime.MinValue; 1887return DateTime.MinValue;
Handlers\AssemblyResourceLoader.cs (1)
640cachePolicy.SetExpires(DateTime.Now + TimeSpan.FromDays(365));
Hosting\ApplicationManager.cs (1)
1712return id + "-" + domainCount.ToString(NumberFormatInfo.InvariantInfo) + "-" + DateTime.UtcNow.ToFileTime().ToString();
Hosting\HostingEnvironment.cs (6)
571DateTime waitUntil = DateTime.UtcNow.AddSeconds(shutdownTimeoutSeconds); 572while (_registeredObjects.Count > 0 && DateTime.UtcNow < waitUntil) { 839itm.LastEvent = DateTime.UtcNow; 852itm.LastEvent = DateTime.UtcNow; 868return -(int)(DateTime.UtcNow - itm.LastEvent).TotalSeconds;
Hosting\IIS7WorkerRequest.cs (8)
93private DateTime _clientCertValidFrom; 94private DateTime _clientCertValidUntil; 2437public override DateTime GetClientCertificateValidFrom() { 2444public override DateTime GetClientCertificateValidUntil() { 2510_clientCertValidFrom = (notBefore != 0) ? DateTime.FromFileTime(notBefore) : DateTime.Now; 2511_clientCertValidUntil = (notAfter != 0) ? DateTime.FromFileTime(notAfter) : DateTime.Now;
Hosting\ISAPIWorkerRequest.cs (9)
635private DateTime _clientCertValidFrom; 636private DateTime _clientCertValidUntil; 1520public override DateTime GetClientCertificateValidFrom() { 1527public override DateTime GetClientCertificateValidUntil() { 1588_clientCertValidFrom = DateTime.FromFileTime(pDates[0]); 1590_clientCertValidFrom = DateTime.Now; 1593_clientCertValidUntil = DateTime.FromFileTime(pDates[1]); 1595_clientCertValidUntil = DateTime.Now; 3090internal override DateTime GetStartTime() {
Hosting\MapPathBasedVirtualPathProvider.cs (1)
43public override CacheDependency GetCacheDependency(string virtualPath, IEnumerable virtualPathDependencies, DateTime utcStart) {
Hosting\VirtualPathProvider.cs (3)
83public virtual CacheDependency GetCacheDependency(string virtualPath, IEnumerable virtualPathDependencies, DateTime utcStart) { 92internal CacheDependency GetCacheDependency(VirtualPath virtualPath, IEnumerable virtualPathDependencies, DateTime utcStart) { 272new SingleObjectCollection(virtualPath.VirtualPathString), DateTime.MaxValue);
HttpCachePolicy.cs (40)
196internal readonly DateTime _utcExpires; 204internal readonly DateTime _utcTimestampCreated; 208internal readonly DateTime _utcLastModified; 233DateTime utcExpires, 241DateTime utcTimestampCreated, 245DateTime utcLastModified, 384internal DateTime UtcExpires {get {return _utcExpires ;}} 395internal DateTime UtcTimestampCreated {get {return _utcTimestampCreated ;}} 408internal DateTime UtcLastModified {get {return _utcLastModified ;}} 466DateTime _utcExpires; 473DateTime _utcTimestampCreated; 475DateTime _utcTimestampRequest; 480DateTime _utcLastModified; 530_utcExpires = DateTime.MinValue; 538_utcTimestampCreated = DateTime.MinValue; 539_utcTimestampRequest = DateTime.MinValue; 543_utcLastModified = DateTime.MinValue; 572DateTime utcTimestampRequest) { 701DateTime UpdateLastModifiedTimeFromDependency(CacheDependency dep) { 702DateTime utcFileLastModifiedMax = dep.UtcLastModified; 710DateTime utcNow = DateTime.UtcNow; 740DateTime utcFileLastModifiedMax = UpdateLastModifiedTimeFromDependency(dep); 759DateTime utcFileLastModifiedMax = UpdateLastModifiedTimeFromDependency(dep); 779if (_utcTimestampCreated == DateTime.MinValue) { 980DateTime utcExpires; 1180internal DateTime UtcGetAbsoluteExpiration() { 1181DateTime absoluteExpiration = Cache.NoAbsoluteExpiration; 1183Debug.Assert(_utcTimestampCreated != DateTime.MinValue, "_utcTimestampCreated != DateTime.MinValue"); 1450public void SetExpires(DateTime date) { 1451DateTime utcDate, utcNow; 1454utcNow = DateTime.UtcNow; 1471public DateTime GetExpires() { 1669public void SetLastModified(DateTime date) { 1670DateTime utcDate = DateTimeUtil.ConvertToUniversalTime(date); 1674void UtcSetLastModified(DateTime utcDate) { 1682DateTime utcNow = DateTime.UtcNow; 1705public DateTime GetUtcLastModified() { 1787public DateTime UtcTimestampCreated {
HttpClientCertificate.cs (6)
92public DateTime ValidFrom { get { return _ValidFrom;}} 98public DateTime ValidUntil { get { return _ValidUntil;}} 270private DateTime _ValidFrom = DateTime.Now; 271private DateTime _ValidUntil = DateTime.Now;
HttpContext.cs (7)
83private DateTime _utcTimestamp; 476_utcTimestamp = DateTime.UtcNow; 1390public DateTime Timestamp { 1394internal DateTime UtcTimestamp { 1758Interlocked.Exchange(ref _timeoutStartTimeUtcTicks, DateTime.UtcNow.Ticks); 1774internal Thread MustTimeout(DateTime utcNow) { 1820if (expirationUtcTicks >= DateTime.UtcNow.Ticks) {
HttpCookie.cs (6)
38private DateTime _expires; 226public DateTime Expires { 228return(_expirationSet ? _expires : DateTime.MinValue); 401DateTime dt; 402if (DateTime.TryParse(attributeValue, out dt)) { 466if (_expirationSet && _expires != DateTime.MinValue) {
HttpResponse.cs (15)
102DateTime _expiresAbsolute; 810double seconds = (_cachePolicy.UtcGetAbsoluteExpiration() - DateTime.UtcNow).TotalSeconds; 961internal void AddFileDependencies(string[] filenames, DateTime utcTime) { 2159_expiresAbsolute = DateTime.MinValue; 3151public DateTime ExpiresAbsolute { 3545private DateTime _oldestDependency; 3559DateTime utcNow = DateTime.UtcNow; 3565if (_oldestDependency == DateTime.MinValue || utcNow < _oldestDependency) 3583AddDependencies(items, argname, cloneArray, DateTime.UtcNow); 3591AddDependencies(items, argname, cloneArray, DateTime.UtcNow); 3594internal void AddDependencies(string[] items, string argname, bool cloneArray, DateTime utcDepTime) { 3623if (_oldestDependency == DateTime.MinValue || utcDepTime < _oldestDependency) 3701internal readonly DateTime utcDate; 3703internal ResponseDependencyInfo(string[] items, DateTime utcDate) {
HttpRuntime.cs (20)
203private DateTime _firstRequestStartTime; 210private DateTime _lastShutdownAttemptTime; 394_firstRequestStartTime = DateTime.UtcNow; 713_firstRequestStartTime = DateTime.UtcNow; 1910TimeSpan elapsed = DateTime.UtcNow.Subtract(context.WorkerRequest.GetStartTime()); 1941DateTime waitLimit = DateTime.UtcNow.AddMilliseconds(waitTimeoutMs); 1950if (!System.Diagnostics.Debugger.IsAttached && DateTime.UtcNow > waitLimit) { 2152Debug.Trace("AppDomainFactorySpecial", "Call SetUserForcedShutdown: FileName=" + e.FileName + "; now=" + DateTime.Now); 2177DateTime maxWait = DateTime.UtcNow.AddSeconds(maxWaitChangeNotification); 2180while (DateTime.UtcNow < maxWait) { 2181if (DateTime.UtcNow > _theRuntime.LastShutdownAttemptTime.AddSeconds(waitChangeNotification)) 2228if (_theRuntime.LastShutdownAttemptTime == DateTime.MinValue && !_theRuntime._firstRequestCompleted && !_theRuntime._userForcedShutdown) { 2239if (DateTime.UtcNow < _theRuntime._firstRequestStartTime.AddSeconds(delayTimeoutSec)) { 2258_theRuntime.LastShutdownAttemptTime = DateTime.UtcNow; 2397DateTime begin = wr.GetStartTime(); 2399TimeSpan elapsed = DateTime.UtcNow.Subtract(begin); 2446private DateTime LastShutdownAttemptTime { 2448DateTime dt;
httpserverutility.cs (7)
1513internal static String FormatHttpDateTime(DateTime dt) { 1514if (dt < DateTime.MaxValue.AddDays(-1) && dt > DateTime.MinValue.AddDays(1)) 1519internal static String FormatHttpDateTimeUtc(DateTime dt) { 1523internal static String FormatHttpCookieDateTime(DateTime dt) { 1524if (dt < DateTime.MaxValue.AddDays(-1) && dt > DateTime.MinValue.AddDays(1))
IdleTimeoutMonitor.cs (5)
19private DateTime _lastEvent; // idle since this time 26_lastEvent = DateTime.UtcNow; 41internal DateTime LastEvent { // thread-safe property 43DateTime t; 70if (DateTime.UtcNow <= LastEvent.Add(_idleTimeout))
Management\AppDomainResourcePerfCounters.cs (4)
73private DateTime _LastCollectTime; 81_LastCollectTime = DateTime.UtcNow; 117DateTime dtUtcNow = DateTime.UtcNow;
Management\BufferedWebEventProvider.cs (1)
68DateTime.MinValue,
Management\SimpleMailWebEventProvider.cs (4)
67void GenerateWarnings(StringBuilder sb, DateTime lastFlush, int discardedSinceLastFlush, 143DateTime lastFlush, 201DateTime.MinValue, // lastFlush 238DateTime lastFlush,
Management\SqlWebEventProvider.cs (5)
38DateTime _retryDate = DateTime.MinValue; // Won't try sending unless DateTime.UtcNow is > _retryDate 175void WriteToSQL(WebBaseEventCollection events, int eventsDiscardedByBuffer, DateTime lastNotificationUtc) { 177if (_retryDate > DateTime.UtcNow) { 247_retryDate = DateTime.UtcNow.AddSeconds(timeout);
Management\TemplatedMailWebEventProvider.cs (6)
98DateTime lastNotificationUtc, 154DateTime.MinValue, // lastNotificationUtc 192DateTime lastNotificationUtc, 238DateTime _lastNotificationUtc; 254DateTime lastNotificationUtc, 319public DateTime LastNotificationUtc {
Management\webeventbuffer.cs (22)
44DateTime _lastNotification; 53DateTime lastNotification, 68public DateTime LastNotificationUtc { 109DateTime _lastFlushTime = DateTime.MinValue; 110DateTime _lastScheduledFlushTime = DateTime.MinValue; 111DateTime _lastAdd = DateTime.MinValue; 112DateTime _startTime = DateTime.MinValue; 181_startTime = DateTime.UtcNow; 225bool AnticipateBurst(DateTime now) { 242DateTime now = DateTime.UtcNow; 310DateTime nowUtc = DateTime.UtcNow; 312DateTime lastFlushTime = DateTime.MaxValue; 512Debug.Assert(lastFlushTime != DateTime.MaxValue, "lastFlushTime != DateTime.MaxValue"); 578_lastAdd = DateTime.UtcNow; 589string PrintTime(DateTime t) {
Management\WebEvents.cs (17)
121DateTime _eventTimeUtc; 179_eventTimeUtc = DateTime.UtcNow; 206public DateTime EventTime { get { return _eventTimeUtc.ToLocalTime(); } } 208public DateTime EventTimeUtc { get { return _eventTimeUtc; } } 2040static DateTime s_startTime = DateTime.MinValue; 2041static DateTime s_lastUpdated = DateTime.MinValue; 2067DateTime now = DateTime.Now; 2103public DateTime ProcessStartTime {get {Update(); return s_startTime;}} 2186internal DateTime _lastFired; 2192public DateTime LastFired { get { return _lastFired; } } 2206_lastFired = DateTime.MinValue; 2211void UpdateLastFired(DateTime now, bool alreadyLocked) { 2238DateTime now = DateTime.Now;
Management\wmiprovider.cs (1)
42string WmiFormatTime(DateTime dt) {
OutputCacheModule.cs (5)
544DateTime utcIfModifiedSince; 1237DateTime utcExpires = Cache.NoAbsoluteExpiration; 1244DateTime utcTimestamp = (settings.UtcTimestampCreated != DateTime.MinValue) ? settings.UtcTimestampCreated : context.UtcTimestamp; 1252if (utcExpires > DateTime.UtcNow) {
ProcessInfo.cs (4)
101public DateTime StartTime { get { return _StartTime;}} 130private DateTime _StartTime; 142public void SetAll (DateTime startTime, TimeSpan age, int processID, int requestCount, ProcessStatus status, 158public ProcessInfo (DateTime startTime, TimeSpan age, int processID, int requestCount, ProcessStatus status,
ProcessModelInfo.cs (7)
39DateTime startTime = DateTime.FromFileTime(tmCreateTime); 40TimeSpan age = DateTime.Now.Subtract(startTime); 75DateTime startTime = DateTime.FromFileTime(tmCrea[iter]); 76TimeSpan age = DateTime.Now.Subtract(startTime); 83age = DateTime.FromFileTime(tmDeat[iter]).Subtract(startTime);
Profile\HttpProfileBase.cs (5)
157public DateTime LastActivityDate { 164public DateTime LastUpdatedDate { 570return typeof(DateTime); 635private DateTime _LastActivityDate; 636private DateTime _LastUpdatedDate;
Profile\ProfileInfo.cs (6)
29public ProfileInfo(string username, bool isAnonymous, DateTime lastActivityDate, DateTime lastUpdatedDate, int size) 52public virtual DateTime LastActivityDate { get { return _LastActivityDate.ToLocalTime();} } 53public virtual DateTime LastUpdatedDate { get { return _LastUpdatedDate.ToLocalTime(); } } 59private DateTime _LastActivityDate; 60private DateTime _LastUpdatedDate;
Profile\ProfileManager.cs (7)
95public static int DeleteInactiveProfiles(ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate) 105return Provider.GetNumberOfInactiveProfiles(authenticationOption, DateTime.Now.AddDays(1)); // 111public static int GetNumberOfInactiveProfiles(ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate) 143DateTime userInactiveSinceDate) 154DateTime userInactiveSinceDate, 214DateTime userInactiveSinceDate) 232DateTime userInactiveSinceDate,
Profile\ProfileProvider.cs (4)
31public abstract int DeleteInactiveProfiles (ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate); 32public abstract int GetNumberOfInactiveProfiles (ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate); 35public abstract ProfileInfoCollection GetAllInactiveProfiles (ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate, int pageIndex, int pageSize, out int totalRecords); 37public abstract ProfileInfoCollection FindInactiveProfilesByUserName(ProfileAuthenticationOption authenticationOption, string usernameToMatch, DateTime userInactiveSinceDate, int pageIndex, int pageSize, out int totalRecords);
Profile\SqlProfileProvider.cs (9)
169cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 238cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 377public override int DeleteInactiveProfiles(ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate) 411public override int GetNumberOfInactiveProfiles(ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate) 454public override ProfileInfoCollection GetAllInactiveProfiles(ProfileAuthenticationOption authenticationOption, DateTime userInactiveSinceDate, int pageIndex, int pageSize, out int totalRecords) 472public override ProfileInfoCollection FindInactiveProfilesByUserName(ProfileAuthenticationOption authenticationOption, string usernameToMatch, DateTime userInactiveSinceDate, int pageIndex, int pageSize, out int totalRecords) 522DateTime dtLastActivity, dtLastUpdated; 527dtLastActivity = DateTime.SpecifyKind(reader.GetDateTime(2), DateTimeKind.Utc); 528dtLastUpdated = DateTime.SpecifyKind(reader.GetDateTime(3), DateTimeKind.Utc);
RequestQueue.cs (1)
125if (DateTime.UtcNow - wr.GetStartTime() > _clientConnectedTime)
RequestTimeoutManager.cs (4)
62CancelTimedOutRequests(DateTime.UtcNow.AddYears(1)); // future date 67CancelTimedOutRequests(DateTime.UtcNow); 70private void CancelTimedOutRequests(DateTime now) { 173internal void TimeoutIfNeeded(DateTime now) {
Security\ADMembershipProvider.cs (29)
116private readonly DateTime DefaultLastLockoutDate = new DateTime(1754, 1, 1, 0, 0, 0, DateTimeKind.Utc); 2637DateTime currentTime = DateTime.UtcNow; 2640DateTime lastBadPasswordAnswerTime = GetDateTimeFromLargeInteger((NativeComInterfaces.IAdsLargeInteger) PropertyManager.GetPropertyValue(userEntry, attributeMapFailedPasswordAnswerTime)); 2735DateTime lockoutTime = DateTime.FromFileTimeUtc((Int64) PropertyManager.GetSearchResultPropertyValue(res, "lockoutTime")); 2736DateTime currentTime = DateTime.UtcNow; 2759DateTime lastLockoutDate = DefaultLastLockoutDate; 2761lastLockoutDate = DateTime.FromFileTime((Int64) PropertyManager.GetSearchResultPropertyValue(res, "lockoutTime")); 2769DateTime badPasswordAnswerLockoutTime = DateTime.FromFileTimeUtc((Int64) PropertyManager.GetSearchResultPropertyValue(res, attributeMapFailedPasswordAnswerLockoutTime)); 2770DateTime currentTime = DateTime.UtcNow; 2782if (DateTime.Compare(badPasswordAnswerLockoutTime, DateTime.FromFileTimeUtc((Int64) PropertyManager.GetSearchResultPropertyValue(res, "lockoutTime"))) > 0) 2783lastLockoutDate = DateTime.FromFileTime((Int64) PropertyManager.GetSearchResultPropertyValue(res, attributeMapFailedPasswordAnswerLockoutTime)); 2791lastLockoutDate = DateTime.FromFileTime((Int64) PropertyManager.GetSearchResultPropertyValue(res, attributeMapFailedPasswordAnswerLockoutTime)); 2797DateTime whenCreated = ((DateTime) PropertyManager.GetSearchResultPropertyValue(res, "whenCreated")).ToLocalTime(); 2800DateTime lastLogon = DateTime.MinValue; 2803DateTime lastActivity = DateTime.MinValue; 2806DateTime lastPasswordChange = DateTime.FromFileTime((Int64) PropertyManager.GetSearchResultPropertyValue(res, "pwdLastSet")); 3364private DateTime GetDateTimeFromLargeInteger(NativeComInterfaces.IAdsLargeInteger largeIntValue) 3374return DateTime.FromFileTimeUtc(int64Value); 3378private NativeComInterfaces.IAdsLargeInteger GetLargeIntegerFromDateTime(DateTime dateTimeValue)
Security\ADMembershipUser.cs (12)
33public override DateTime LastLoginDate 45public override DateTime LastActivityDate 114DateTime creationDate, 115DateTime lastLoginDate, 116DateTime lastActivityDate, 117DateTime lastPasswordChangedDate, 118DateTime lastLockoutDate) 156DateTime creationDate, 157DateTime lastLoginDate, 158DateTime lastActivityDate, 159DateTime lastPasswordChangedDate, 160DateTime lastLockoutDate,
Security\AnonymousIdentificationModule.cs (9)
241DateTime dtNow = DateTime.UtcNow; 258DateTime dtExpireTime = dtNow.AddMinutes(s_CookieTimeout); 364DateTime expireDate = DateTime.FromFileTimeUtc(BitConverter.ToInt64(bBlob, 0)); 365if (expireDate < DateTime.UtcNow) 389internal AnonymousIdData(string id, DateTime dt) { 391AnonymousId = (dt > DateTime.UtcNow) ? id : null; // Ignore expired data 395internal DateTime ExpireDate;
Security\AuthStoreRoleProvider.cs (4)
482private DateTime _LastUpdateCacheDate; 532if (DateTime.Now > _LastUpdateCacheDate.AddMinutes(CacheRefreshInterval)) { 533_LastUpdateCacheDate = DateTime.Now; 633_LastUpdateCacheDate = DateTime.Now;
Security\FormsAuthentication.cs (10)
215DateTime dt1 = DateTime.FromFileTime(pDates[0]); 216DateTime dt2 = DateTime.FromFileTime(pDates[1]); 489DateTime issueDateUtc = DateTime.UtcNow; 490DateTime expirationUtc = issueDateUtc.AddMinutes(_Timeout); 619DateTime utcNow = DateTime.UtcNow; 630DateTime newExpirationUtc = utcNow + originalTicketTotalLifetime;
Security\FormsAuthenticationTicket.cs (17)
44public DateTime Expiration { get { return _Expiration;}} 50public DateTime IssueDate { get { return _IssueDate;}} 68return (ExpirationUtc < DateTime.UtcNow); 134internal DateTime ExpirationUtc { 138internal DateTime IssueDateUtc { 144private DateTime _Expiration; 145private DateTime _IssueDate; 164private DateTime _ExpirationUtc; 168private DateTime _IssueDateUtc; 177DateTime issueDate, 178DateTime expiration, 193DateTime issueDate, 194DateTime expiration, 218_IssueDateUtc = DateTime.UtcNow; 219_IssueDate = DateTime.Now; 228internal static FormsAuthenticationTicket FromUtc(int version, String name, DateTime issueDateUtc, DateTime expirationUtc, bool isPersistent, String userData, String cookiePath) {
Security\FormsAuthenticationTicketSerializer.cs (4)
69DateTime ticketIssueDateUtc = new DateTime(ticketIssueDateUtcTicks, DateTimeKind.Utc); 70DateTime ticketIssueDateLocal = ticketIssueDateUtc.ToLocalTime(); 82DateTime ticketExpirationDateUtc = new DateTime(ticketExpirationDateUtcTicks, DateTimeKind.Utc); 83DateTime ticketExpirationDateLocal = ticketExpirationDateUtc.ToLocalTime();
Security\RolePrincipal.cs (10)
126if (DateTime.UtcNow > rp._ExpireDate) 161_IssueDate = DateTime.UtcNow; 162_ExpireDate = DateTime.UtcNow.AddMinutes(Roles.CookieTimeout); 215public DateTime ExpireDate { get { return _ExpireDate.ToLocalTime();}} 216public DateTime IssueDate { get { return _IssueDate.ToLocalTime();}} 220public bool Expired { get { return _ExpireDate < DateTime.UtcNow;}} 278DateTime dtN = DateTime.UtcNow; 431private DateTime _ExpireDate; 432private DateTime _IssueDate;
Security\SQLMembershipProvider.cs (37)
360DateTime dt = RoundToSeconds(DateTime.UtcNow); 630cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 689DateTime lastLoginDate, lastActivityDate; 752cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 833cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 944cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 956DateTime dtCreate = reader.GetDateTime(4).ToLocalTime(); 957DateTime dtLastLogin = reader.GetDateTime(5).ToLocalTime(); 958DateTime dtLastActivity = reader.GetDateTime(6).ToLocalTime(); 959DateTime dtLastPassChange = reader.GetDateTime(7).ToLocalTime(); 962DateTime dtLastLockoutDate = reader.GetDateTime(10).ToLocalTime(); 1033cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 1045DateTime dtCreate = reader.GetDateTime(4).ToLocalTime(); 1046DateTime dtLastLogin = reader.GetDateTime(5).ToLocalTime(); 1047DateTime dtLastActivity = reader.GetDateTime(6).ToLocalTime(); 1048DateTime dtLastPassChange = reader.GetDateTime(7).ToLocalTime(); 1051DateTime dtLastLockoutDate = reader.GetDateTime(10).ToLocalTime(); 1250DateTime dtCreate, dtLastLogin, dtLastActivity, dtLastPassChange; 1253DateTime dtLastLockoutDate; 1324cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 1389DateTime dtCreate, dtLastLogin, dtLastActivity, dtLastPassChange; 1392DateTime dtLastLockoutDate; 1485DateTime dtCreate, dtLastLogin, dtLastActivity, dtLastPassChange; 1488DateTime dtLastLockoutDate; 1558DateTime lastLoginDate, lastActivityDate; 1582DateTime dtNow = DateTime.UtcNow; 1630out DateTime lastLoginDate, 1631out DateTime lastActivityDate) 1649cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 1678lastLoginDate = DateTime.UtcNow; 1679lastActivityDate = DateTime.UtcNow; 1730cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 1797DateTime lastLoginDate, lastActivityDate; 1893private DateTime RoundToSeconds(DateTime utcDateTime)
Security\SQLRoleProvider.cs (1)
474cmd.Parameters.Add(CreateInputParam("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow));
State\InProcStateClientManager.cs (8)
154state._utcLockDate = DateTime.UtcNow; 183lockAge = DateTime.UtcNow - state._utcLockDate; 300DateTime.MinValue, 341DateTime.MinValue, 377DateTime.MinValue, 477internal DateTime _utcLockDate; 489DateTime utcLockDate, 501DateTime utcLockDate,
State\OutOfProcStateClientManager.cs (2)
491DateTime now = DateTime.Now;
State\SessionStateItemCollection.cs (1)
163t=typeof(DateTime);
State\SessionStateModule.cs (4)
229DateTime _rqLastPollCompleted; 499_rqLastPollCompleted = DateTime.MinValue; 1198(DateTime.UtcNow - _rqLastPollCompleted >= LOCKED_ITEM_POLLING_DELTA)) { 1204_rqLastPollCompleted = DateTime.UtcNow;
State\sqlstateclientmanager.cs (12)
531DateTime lockDate; 532lockDate = (DateTime) cmd.Parameters[3].Value; 533lockAge = DateTime.Now - lockDate; 830ref bool isFirstAttempt, ref DateTime endRetryTime) { 856endRetryTime = DateTime.UtcNow.Add(s_retryInterval); 861if (DateTime.UtcNow > endRetryTime) { 875DateTime endRetryTime = DateTime.UtcNow; 914DateTime endRetryTime = DateTime.UtcNow; 1190DateTime endRetryTime = DateTime.UtcNow;
State\StateRuntime.cs (6)
219internal DateTime _utcLockDate; 231DateTime utcLockDate, 306DateTime localLockDate; 315lockAge = (DateTime.UtcNow - content._utcLockDate).Ticks / TimeSpan.TicksPerSecond; 481content._utcLockDate = DateTime.UtcNow; 622content = new CachedContent(buf, stateItem, false, DateTime.MinValue, timeout, lockCookieNew, extraFlags);
StaticFileHandler.cs (9)
54private static bool IsOutDated(string ifRangeHeader, DateTime lastModified) { 56DateTime utcLastModified = lastModified.ToUniversalTime(); 57DateTime utc = HttpDate.UtcParse(ifRangeHeader); 65private static string GenerateETag(HttpContext context, DateTime lastModified, DateTime now) { 334DateTime lastModified) { 485DateTime lastModifiedInUtc; 525DateTime utcNow = DateTime.UtcNow;
UI\ControlCachePolicy.cs (1)
149public void SetExpires(DateTime expirationTime) {
UI\DataSourceCache.cs (2)
203DateTime utcAbsoluteExpiryTime = Cache.NoAbsoluteExpiration; 209utcAbsoluteExpiryTime = DateTime.UtcNow.AddSeconds(Duration == 0 ? Int32.MaxValue : Duration);
UI\LegacyPageAsyncTaskManager.cs (7)
24private DateTime _timeoutEnd; 81if (!_timeoutEndReached && (DateTime.UtcNow >= _timeoutEnd)) { 100DateTime utcNow = DateTime.UtcNow; 149_timeoutEnd = DateTime.UtcNow + _page.AsyncTimeout; 349DateTime utcNow = DateTime.UtcNow;
UI\ObjectConverter.cs (3)
58else if (typeof(DateTime).IsAssignableFrom(toType)) { 107else if (typeof(DateTime).IsAssignableFrom(fromType)) { 108return((DateTime)value).ToString(formatString, CultureInfo.InvariantCulture);
UI\ObjectStateFormatter.cs (3)
545return DateTime.FromBinary(reader.ReadInt64()); 981if (value is DateTime) { 983writer.Write(((DateTime)value).ToBinary());
UI\Page.cs (1)
792long ticks = DateTime.Now.Ticks % 999983;
UI\PartialCachingControl.cs (7)
62internal DateTime _utcExpirationTime; 300if (_utcExpirationTime == DateTime.MaxValue) 303return _utcExpirationTime - DateTime.UtcNow; 310_utcExpirationTime = DateTime.MaxValue; 314_utcExpirationTime = DateTime.UtcNow.Add(value); 419DateTime utcExpirationTime; 423slidingExpiration = _utcExpirationTime - DateTime.UtcNow;
UI\SessionPageStatePersister.cs (1)
102string sessionViewStateID = Convert.ToString(DateTime.Now.Ticks, 16);
UI\TemplateParser.cs (2)
803System.Web.Util.Debug.Trace("Template", "Starting parse at " + DateTime.Now); 874System.Web.Util.Debug.Trace("Template", "Ending parse at " + DateTime.Now);
UI\Util.cs (1)
436string uniqueToken = DateTime.Now.Ticks.GetHashCode().ToString("x", CultureInfo.InvariantCulture);
UI\WebControls\AdRotator.cs (1)
511(type == typeof(DateTime)) ||
UI\WebControls\basecomparevalidator.cs (7)
116int currentYear = DateTime.Today.Year; 232value = DateTime.Parse(text, CultureInfo.CurrentCulture); 417compareResult = ((DateTime)leftObject).CompareTo(rightObject); 464DateTime date; 465if (DateTime.TryParse(text, CultureInfo.CurrentCulture, DateTimeStyles.None, out date)) { 482if (value is DateTime) { 484return ((DateTime) value).ToShortDateString();
UI\WebControls\BaseDataList.cs (1)
528(type == typeof(DateTime)) ||
UI\WebControls\Calendar.cs (47)
30ControlValueProperty("SelectedDate", typeof(DateTime), "1/1/0001"), 60private DateTime minSupportedDate; 61private DateTime maxSupportedDate; 69private static DateTime baseDate = new DateTime(2000, 1, 1); 401DefaultValue(typeof(DateTime), "1/1/0001"), 404public DateTime SelectedDate { 407return DateTime.MinValue; 412if (value == DateTime.MinValue) { 423/// <para>Gets a collection of <see cref='System.DateTime' qualify='true'/> objects representing days selected on the <see cref='System.Web.UI.WebControls.Calendar'/>. This 717public DateTime TodaysDate { 720return((o == null) ? DateTime.Today : (DateTime)o); 750DefaultValue(typeof(DateTime), "1/1/0001"), 753public DateTime VisibleDate { 756return((o == null) ? DateTime.MinValue : (DateTime)o); 900private DateTime EffectiveVisibleDate() { 901DateTime visDate = VisibleDate; 902if (visDate.Equals(DateTime.MinValue)) { 918private DateTime FirstCalendarDay(DateTime visibleDate) { 919DateTime firstDayOfMonth = visibleDate; 1005private bool IsTheSameYearMonth(DateTime date1, DateTime date2) { 1014private bool IsMinSupportedYearMonth(DateTime date) { 1021private bool IsMaxSupportedYearMonth(DateTime date) { 1140protected virtual void OnVisibleMonthChanged(DateTime newDate, DateTime previousDate) { 1166DateTime oldDate = VisibleDate; 1167if (oldDate.Equals(DateTime.MinValue)) { 1172if (VisibleDate == DateTime.MinValue) { 1192DateTime dt = baseDate.AddDays(dayDiff); 1198DateTime dt = baseDate.AddDays(dayDiff); 1230DateTime visibleDate = EffectiveVisibleDate(); 1231DateTime firstDay = FirstCalendarDay(visibleDate); 1357private void RenderDayHeader(HtmlTextWriter writer, DateTime visibleDate, CalendarSelectionMode selectionMode, bool buttonsActive, bool useAccessibleHeader) { 1445private void RenderDays(HtmlTextWriter writer, DateTime firstDay, DateTime visibleDate, CalendarSelectionMode selectionMode, bool buttonsActive, bool useAccessibleHeader) { 1448DateTime d = firstDay; 1474DateTime todaysDate = TodaysDate; 1511DateTime secondLastMonth = threadCalendar.AddMonths(maxSupportedDate, -1); 1666private void RenderTitle(HtmlTextWriter writer, DateTime visibleDate, CalendarSelectionMode selectionMode, bool buttonsActive, bool useAccessibleHeader) { 1707DateTime prevMonthDate; 1714DateTime secondSupportedMonth = threadCalendar.AddMonths(minSupportedDate, 1); 1783DateTime nextMonthDate = threadCalendar.AddMonths(visibleDate, 1); 1830private void SelectRange(DateTime dateFrom, DateTime dateTo) {
UI\WebControls\CalendarDay.cs (3)
17private DateTime date; 29public CalendarDay(DateTime date, bool isWeekend, bool isToday, bool isSelected, bool isOtherMonth, string dayNumberText) { 43public DateTime Date {
UI\WebControls\DataBoundControlHelper.cs (1)
93(type == typeof(DateTime)) ||
UI\WebControls\MonthChangedEventArgs.cs (5)
14DateTime newDate, previousDate; 20public MonthChangedEventArgs(DateTime newDate, DateTime previousDate) { 30public DateTime NewDate { 41public DateTime PreviousDate {
UI\WebControls\SelectedDatesCollection.cs (13)
40/// <para>Gets a <see cref='System.DateTime' qualify='true'/> referenced by the specified ordinal index value in the collection.</para> 42public DateTime this[int index] { 44return(DateTime) dateList[index]; 50/// <para>Adds the specified <see cref='System.DateTime'/> to the end of the collection.</para> 52public void Add(DateTime date) { 61/// <para>Removes all <see cref='System.DateTime'/> controls from the collection.</para> 72public bool Contains(DateTime date) { 80private bool FindIndex(DateTime date, out int index) { 103/// <para>Returns an enumerator of all <see cref='System.DateTime' qualify='true'/> controls within the collection.</para> 150public void Remove(DateTime date) { 162public void SelectRange(DateTime fromDate, DateTime toDate) { 169DateTime date = fromDate;
UI\WebParts\PersonalizationAdministration.cs (11)
25internal static readonly DateTime DefaultInactiveSinceDate = DateTime.MaxValue; 172public static int ResetInactiveUserState(DateTime userInactiveSinceDate) { 177DateTime userInactiveSinceDate) { 183private static int ResetInactiveUserStatePrivate(string path, DateTime userInactiveSinceDate) { 218public static int GetCountOfInactiveUserState(DateTime userInactiveSinceDate) { 223DateTime userInactiveSinceDate) { 255public static PersonalizationStateInfoCollection GetAllInactiveUserState(DateTime userInactiveSinceDate) { 260public static PersonalizationStateInfoCollection GetAllInactiveUserState(DateTime userInactiveSinceDate, 307DateTime userInactiveSinceDate) { 315DateTime userInactiveSinceDate,
UI\WebParts\PersonalizationProvider.cs (1)
266public abstract int ResetUserState(string path, DateTime userInactiveSinceDate);
UI\WebParts\PersonalizationStateInfo.cs (3)
16private DateTime _lastUpdatedDate; 20internal PersonalizationStateInfo(string path, DateTime lastUpdatedDate, int size) { 33public DateTime LastUpdatedDate {
UI\WebParts\PersonalizationStateQuery.cs (3)
23_knownPropertyTypeMappings["UserInactiveSinceDate"] = typeof(DateTime); 46public DateTime UserInactiveSinceDate { 50return (DateTime) o;
UI\WebParts\SharedPersonalizationStateInfo.cs (1)
18DateTime lastUpdatedDate,
UI\WebParts\SqlPersonalizationProvider.cs (16)
120DateTime lastUpdatedDate = (reader.IsDBNull(1)) ? DateTime.MinValue : 121DateTime.SpecifyKind(reader.GetDateTime(1), DateTimeKind.Utc); 175DateTime inactiveSinceDate = PersonalizationAdministration.DefaultInactiveSinceDate; 189DateTime inactiveSinceDate, 245DateTime lastUpdatedDate = DateTime.SpecifyKind(reader.GetDateTime(1), DateTimeKind.Utc); 248DateTime lastActivityDate = DateTime.SpecifyKind(reader.GetDateTime(4), DateTimeKind.Utc); 365DateTime userInactiveSinceDate = PersonalizationAdministration.DefaultInactiveSinceDate; 376private int GetCountOfUserState(string path, DateTime inactiveSinceDate, string username) { 521command.Parameters.Add(CreateParameter("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 597command.Parameters.Add(CreateParameter("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow)); 747public override int ResetUserState(string path, DateTime userInactiveSinceDate) { 792DateTime userInactiveSinceDate, 922command.Parameters.Add(CreateParameter("@CurrentTimeUtc", SqlDbType.DateTime, DateTime.UtcNow));
UI\WebParts\UserPersonalizationStateInfo.cs (4)
16private DateTime _lastActivityDate; 19DateTime lastUpdatedDate, 22DateTime lastActivityDate) : 34public DateTime LastActivityDate {
UI\WebParts\WebPartManager.cs (2)
2441return typeof(DateTime); 2481else if (type == typeof(DateTime)) {
Util\altserialization.cs (2)
65else if (value is DateTime) { 67writer.Write(((DateTime) value).Ticks);
Util\AspCompat.cs (2)
682_context.Response.Cookies[name].Expires = DateTime.FromOADate(dtExpires); 778_context.Response.ExpiresAbsolute = DateTime.FromOADate(dtExpires);
Util\DateTimeUtil.cs (13)
23static readonly DateTime MinValuePlusOneDay = DateTime.MinValue.AddDays(1); 24static readonly DateTime MaxValueMinusOneDay = DateTime.MaxValue.AddDays(-1); 26static internal DateTime FromFileTimeToUtc(long filetime) { 34static internal DateTime ConvertToUniversalTime(DateTime localTime) { 36return DateTime.MinValue; 40return DateTime.MaxValue; 46static internal DateTime ConvertToLocalTime(DateTime utcTime) { 48return DateTime.MinValue; 52return DateTime.MaxValue;
Util\Debug.cs (2)
1080static internal string FormatUtcDate(DateTime utcTime) { 1089static internal string FormatLocalDate(DateTime localTime) {
Util\FileUtil.cs (3)
571internal readonly DateTime UtcCreationTime; 572internal readonly DateTime UtcLastAccessTime; 573internal readonly DateTime UtcLastWriteTime;
Util\HashCodeCombiner.cs (1)
109internal void AddDateTime(DateTime dt) {
Util\ParseHttpDate.cs (1)
150static internal DateTime UtcParse(string time)
Util\ReadWriteSpinLock.cs (2)
267DateTime utcSpinStartTime = DateTime.UtcNow; // error if struct not initialized
VirtualPath.cs (1)
287public CacheDependency GetCacheDependency(IEnumerable virtualPathDependencies, DateTime utcStart) {
WebSockets\AspNetWebSocketContext.cs (1)
165public virtual DateTime Timestamp {
WebSockets\AspNetWebSocketContextImpl.cs (1)
227public override DateTime Timestamp {
WorkerRequest.cs (8)
45private DateTime _startTime; 56_startTime = DateTime.UtcNow; 838internal virtual DateTime GetStartTime() { 848_startTime = DateTime.UtcNow; 1126public virtual DateTime GetClientCertificateValidFrom() { 1127return DateTime.Now; 1135public virtual DateTime GetClientCertificateValidUntil() { 1136return DateTime.Now;
System.Web.ApplicationServices (17)
Security\MembershipUser.cs (17)
57public virtual DateTime LastLockoutDate 62public virtual DateTime CreationDate { 66public virtual DateTime LastLoginDate { 71public virtual DateTime LastActivityDate { 76public virtual DateTime LastPasswordChangedDate { 83DateTime dt = DateTime.UtcNow.Subtract(ts); 110DateTime creationDate, 111DateTime lastLoginDate, 112DateTime lastActivityDate, 113DateTime lastPasswordChangedDate, 114DateTime lastLockoutDate ) 384private DateTime _LastLockoutDate; 385private DateTime _CreationDate; 386private DateTime _LastLoginDate; 387private DateTime _LastActivityDate; 388private DateTime _LastPasswordChangedDate;
System.Web.DataVisualization (118)
Common\Converters\AxisConverters.cs (6)
124 return DateTime.FromOADate((double)value).ToShortDateString(); 126 return DateTime.FromOADate((double)value).ToString("g", System.Globalization.CultureInfo.CurrentCulture); 209DateTime valueAsDate; 210bool parseSucceed = DateTime.TryParse(stringValue, CultureInfo.InvariantCulture, DateTimeStyles.None, out valueAsDate); 425DateTime valueAsDate; 426bool parseSucceed = DateTime.TryParse(stringValue, CultureInfo.CurrentCulture, DateTimeStyles.None, out valueAsDate);
Common\Converters\DataManagerConverters.cs (8)
524DateTime valueAsDate; 525if (DateTime.TryParse(values[index], CultureInfo.InvariantCulture, DateTimeStyles.None, out valueAsDate)) 529else if (DateTime.TryParse(values[index], CultureInfo.CurrentCulture, DateTimeStyles.None, out valueAsDate)) 589 result += DateTime.FromOADate(d).ToString("g", System.Globalization.CultureInfo.InvariantCulture) + ","; 630 DateTime valueAsSate = DateTime.FromOADate((double)value); 656DateTime valueAsSate = DateTime.Parse(stringValue, System.Globalization.CultureInfo.CurrentCulture);
Common\DataManager\DataPoint.cs (31)
1005if (yValue[0] is DateTime) 1057 if(xValue is DateTime) 1077if (yValue[0] is DateTime) 1512 if(columnDataType == typeof(DateTime)) 1928 if(obj is DateTime) 1930 doubleObj = ((DateTime)obj).ToOADate(); 2114 else if(paramType == typeof(DateTime)) 2116 this._xValue = ((DateTime)xValue).ToOADate(); 2124 if(base.series != null && xValue is DateTime) 2128 DateTime time = new DateTime( 2129 ((DateTime)xValue).Year, 2130 ((DateTime)xValue).Month, 2131 ((DateTime)xValue).Day, 2140 DateTime time = new DateTime( 2144 ((DateTime)xValue).Hour, 2145 ((DateTime)xValue).Minute, 2146 ((DateTime)xValue).Second, 2147 ((DateTime)xValue).Millisecond); 2244 else if(paramType == typeof(DateTime)) 2251 this._yValue[i] = DateTime.Now.ToOADate(); 2255 this._yValue[i] = ((DateTime)yValue[i]).ToOADate(); 2288 DateTime yDate; 2289 if (yValue[i] is DateTime) 2290 yDate = (DateTime)yValue[i]; 2292 yDate = DateTime.FromOADate((Double)yValue[i]); 2296 DateTime date = new DateTime( 2309 DateTime yTime; 2310 if (yValue[i] is DateTime) 2311 yTime = (DateTime)yValue[i]; 2313 yTime = DateTime.FromOADate((Double)yValue[i]); 2317 DateTime time = new DateTime(
Common\DataManager\DataSeries.cs (15)
925 type == typeof(DateTime) || 996DateTime[] dateValues = { DateTime.Now.Date, DateTime.Now.Date.AddDays(1), DateTime.Now.Date.AddDays(2), DateTime.Now.Date.AddDays(3), DateTime.Now.Date.AddDays(4), DateTime.Now.Date.AddDays(4) }; 1026dateValues = new DateTime[] { DateTime.Now, DateTime.Now.AddMinutes(1), DateTime.Now.AddMinutes(2), DateTime.Now.AddMinutes(3), DateTime.Now.AddMinutes(4), DateTime.Now.AddMinutes(4) };
Common\General\AxisScale.cs (4)
1374 DateTime dateTimeMin = DateTime.FromOADate( min ); 1375 DateTime dateTimeMax = DateTime.FromOADate( max );
Common\General\AxisScrollZoom.cs (5)
1648strValue = DateTime.FromOADate(dtValue).ToString("g", System.Globalization.CultureInfo.CurrentCulture); 1658strValue = DateTime.FromOADate(dtValue).ToShortDateString(); 1662strValue = DateTime.FromOADate(dtValue).ToString("g", System.Globalization.CultureInfo.CurrentCulture); 1752DateTime valueAsDate; 1753bool parseSucceed = DateTime.TryParse(crossingValue, CultureInfo.InvariantCulture, DateTimeStyles.None, out valueAsDate);
Common\General\Chart.cs (1)
876 yValuesObj[i] = (((Series)seriesList[0]).IsYValueDateTime()) ? DateTime.Now.Date.ToOADate() : 0.0;
Common\General\ChartAreaAxes.cs (4)
1968 DateTime date1 = DateTime.FromOADate(value1); 1969 DateTime date2 = DateTime.FromOADate(value2);
Common\General\ChartElement.cs (11)
977 DateTime newStartDate = DateTime.FromOADate(start); 986 DateTime resultDate = newStartDate; 987 DateTime sizeAdjustedDate = new DateTime(newStartDate.Year, 1, 1, 0, 0, 0); 1197 DateTime dateValue = DateTime.FromOADate(series.Points[pointIndex].XValue); 1198 DateTime roundedDateValue = dateValue; 1284 DateTime date = DateTime.FromOADate(current); 1316 if(date.Day == DateTime.DaysInMonth(date.Year, date.Month)) 1329 int daysInMobth = DateTime.DaysInMonth(date.Year, date.Month);
Common\General\DataManipulator.cs (6)
975 columnType = typeof(DateTime); 990 columnType = typeof(DateTime); 1026xValue = DateTime.FromOADate(point.XValue); 1045yValue = DateTime.FromOADate(point.YValues[yIndex]); 1618 DateTime dateTimeValue = DateTime.FromOADate(point.XValue);
Common\General\Label.cs (8)
290labelEnd = DateTime.FromOADate(labelStart).AddMilliseconds(labelsStep).ToOADate(); 294labelEnd = DateTime.FromOADate(labelStart).AddSeconds(labelsStep).ToOADate(); 298labelEnd = DateTime.FromOADate(labelStart).AddMinutes(labelsStep).ToOADate(); 302labelEnd = DateTime.FromOADate(labelStart).AddHours(labelsStep).ToOADate(); 306labelEnd = DateTime.FromOADate(labelStart).AddDays(labelsStep).ToOADate(); 310labelEnd = DateTime.FromOADate(labelStart).AddDays(7 * labelsStep).ToOADate(); 314labelEnd = DateTime.FromOADate(labelStart).AddMonths((int)labelsStep).ToOADate(); 318labelEnd = DateTime.FromOADate(labelStart).AddYears((int)labelsStep).ToOADate();
Common\Utilities\ValueConverter.cs (2)
120result = String.Format(CultureInfo.CurrentCulture, convertionFormat, DateTime.FromOADate(value)); 131result = String.Format(CultureInfo.CurrentCulture, convertionFormat, DateTime.FromOADate(value));
Common\Utilities\XmlSerializer.cs (3)
2715 else if(obj is DateTime) 2718 writer.Write(((DateTime)obj).Ticks); 3127 else if(pi.PropertyType == typeof(DateTime))
WebForm\ChartWebControl.cs (3)
891DateTime fileTime = File.GetLastWriteTime(fileName); 892if (fileTime.AddMinutes(imageTimeToLive) > DateTime.Now) 907TimeSpan timeSpan = DateTime.Now - fileTime;
WebForm\General\ChartHttpHandler.cs (11)
223TimeSpan lastWrite = DateTime.Now - Directory.GetLastWriteTime(Settings.Directory + _controllerDirectory); 1745internal DateTime Created = DateTime.Now; 1792this._current.Value.Created = DateTime.Now - this._itemLifeTime - TimeSpan.FromSeconds(1); 1810internal bool IsExpired(RingItem item, DateTime now) 1823DateTime now = DateTime.Now; 1889DateTime now = DateTime.Now; 2004DateStamp = DateTime.Now; 2016public DateTime DateStamp { get; private set; }
System.Web.DynamicData (5)
DynamicData\DataSourceUtil.cs (1)
32typeNameToTypeCode[typeof(DateTime)] = TypeCode.DateTime;
DynamicData\FieldTemplateFactory.cs (1)
86_typesFallBacks[typeof(DateTime)] = typeof(string);
DynamicData\FieldTemplateUserControl.cs (1)
453if (column.ColumnType == typeof(DateTime)) {
DynamicData\MetaColumn.cs (1)
325if (ColumnType == typeof(DateTime)) return true;
DynamicData\Util\FileChangeNotifier.cs (1)
53virtualPath, virtualPathDependencies, DateTime.UtcNow);
System.Web.Entity (2)
System\Data\WebControls\EntityDataSourceUtil.cs (2)
328return typeof(DateTime); 403return typeof(DateTime);
System.Web.Extensions (57)
ClientServices\Providers\ClientData.cs (10)
61DateTime.UtcNow.AddYears(-1), 65DateTime.UtcNow.AddYears(-1), 86else if (_StoredValues[iter] is DateTime) { 89_StoredValues[iter] = DateTime.FromFileTimeUtc(l); 134internal DateTime LastLoggedInDateUtc { get { return (DateTime)_StoredValues[(int)ClientDateStoreOrderEnum.LastLoggedInDateUtc]; } set { _StoredValues[(int)ClientDateStoreOrderEnum.LastLoggedInDateUtc] = value; } } 142internal DateTime RolesCachedDateUtc { get { return (DateTime)_StoredValues[(int)ClientDateStoreOrderEnum.RolesCachedDateUtc]; } set { _StoredValues[(int)ClientDateStoreOrderEnum.RolesCachedDateUtc] = value; } } 195} else if (_StoredValues[iter] is DateTime) { 196writer.WriteValue(((DateTime)_StoredValues[iter]).ToFileTimeUtc().ToString("X", CultureInfo.InvariantCulture));
ClientServices\Providers\ClientFormsAuthenticationMembershipProvider.cs (2)
409cd.LastLoggedInDateUtc = DateTime.UtcNow; 435SqlHelper.AddParameter(conn, cmd, "@Date", DateTime.Now.ToFileTimeUtc().ToString(CultureInfo.InvariantCulture));
ClientServices\Providers\ClientRoleProvider.cs (12)
39private DateTime _CacheExpiryDate = DateTime.UtcNow; 121if (string.Compare(_CurrentUser, p.Identity.Name, StringComparison.OrdinalIgnoreCase) == 0 && DateTime.UtcNow < _CacheExpiryDate) 132_CacheExpiryDate = DateTime.UtcNow; 152_CacheExpiryDate = DateTime.UtcNow; 197_CacheExpiryDate = DateTime.UtcNow.AddMinutes(_CacheTimeout); 255cd.RolesCachedDateUtc = DateTime.UtcNow; 282SqlHelper.AddParameter(conn, cmd, "@Date", DateTime.UtcNow.ToFileTimeUtc().ToString(CultureInfo.InvariantCulture)); 304_CacheExpiryDate = DateTime.UtcNow; 315if (!ConnectivityStatus.IsOffline && _CacheExpiryDate < DateTime.UtcNow) // expired roles 333_CacheExpiryDate = DateTime.FromFileTimeUtc(filetime).AddMinutes(_CacheTimeout); 334if (!ConnectivityStatus.IsOffline && _CacheExpiryDate < DateTime.UtcNow) // expired roles
Handlers\ScriptResourceHandler.cs (4)
250DateTime now = DateTime.Now; 261DateTime now = DateTime.Now;
HttpResponseInternalWrapper.cs (1)
125public override DateTime ExpiresAbsolute {
Script\Serialization\JavaScriptObjectDeserializer.cs (1)
380DateTime dt = new DateTime(ticks * 10000 + JavaScriptSerializer.DatetimeMinTimeTicks, DateTimeKind.Utc);
Script\Serialization\JavaScriptSerializer.cs (3)
212private static void SerializeDateTime(DateTime datetime, StringBuilder sb, SerializationFormat serializationFormat) { 431if (o is DateTime) { 432SerializeDateTime((DateTime)o, sb, serializationFormat);
Script\Serialization\ObjectConverter.cs (2)
369if (o is DateTime) { 374s = ((DateTime)o).ToUniversalTime().ToString("u", CultureInfo.InvariantCulture);
Script\Services\RestHandler.cs (1)
66context.Response.Cache.SetExpires(DateTime.Now.AddSeconds(cacheDuration));
Script\Services\ServicesUtilities.cs (1)
65if (type == typeof(DateTime)) {
Script\Services\WebServiceClientProxyGenerator.cs (6)
25private static DateTime GetAssemblyModifiedTime(Assembly assembly) { 27DateTime writeTime = File.GetLastWriteTime(new Uri(assemblyName.CodeBase).LocalPath); 37DateTime lastModifiedDate = GetAssemblyModifiedTime(webServiceData.TypeData.Type.Assembly); 42DateTime header; 43if (DateTime.TryParse(modifiedSince, out header)) { 55if (lastModifiedDate.ToUniversalTime() < DateTime.UtcNow) {
Script\Services\WebServiceData.cs (3)
124CacheDependency cd = HostingEnvironment.VirtualPathProvider.GetCacheDependency(virtualPath, deps.VirtualPaths, DateTime.Now); 346t == typeof(DateTime) || t == typeof(Guid) || 408if (t.IsPrimitive || t == typeof(object) || t == typeof(string) || t == typeof(DateTime) ||
UI\WebControls\Dynamic.cs (11)
511void F(DateTime x, DateTime y); 515void F(DateTime? x, DateTime? y); 530void F(DateTime x, TimeSpan y); 533void F(DateTime? x, TimeSpan? y); 540void F(DateTime x, DateTime y); 542void F(DateTime? x, DateTime? y); 614typeof(DateTime),
System.Web.Mobile (79)
UI\MobileControls\Adapters\ChtmlCalendarAdapter.cs (22)
165if (Page.IsPostBack && Control.VisibleDate == DateTime.MinValue) 167Control.VisibleDate = DateTime.Today; 240DateTime visibleDate = Control.VisibleDate; 242bool saveVisibleDate = visibleDate != DateTime.MinValue && 243DateTime.Compare(visibleDate, DateTime.Today) != 0 && 341DateTime tempDate; 617DateTime dateTime = DateTime.ParseExact(dateText, dateFormat, null); 716private String GetAbbreviatedDayName(DateTime dateTime) 722private String GetEra(DateTime dateTime) 786private DateTime EffectiveVisibleDate(DateTime visibleDate) 795private DateTime FirstCalendarDay(DateTime visibleDate) 797DateTime firstDayOfMonth = EffectiveVisibleDate(visibleDate); 869DateTime beginDate = EffectiveVisibleDate(Control.VisibleDate); 872DateTime endDate = _threadCalendar.AddMonths(beginDate, 1); 891DateTime tempDate = FirstCalendarDay(Control.VisibleDate); 898DateTime endDate = _threadCalendar.AddDays(Control.VisibleDate, 6); 921private void SelectRange(DateTime dateFrom, DateTime dateTo)
UI\MobileControls\Adapters\WmlCalendarAdapter.cs (22)
147if (Page.IsPostBack && Control.VisibleDate == DateTime.MinValue) 149Control.VisibleDate = DateTime.Today; 222DateTime visibleDate = Control.VisibleDate; 224bool saveVisibleDate = visibleDate != DateTime.MinValue && 225DateTime.Compare(visibleDate, DateTime.Today) != 0 && 324DateTime tempDate; 594DateTime dateTime = DateTime.ParseExact(dateText, dateFormat, null); 693private String GetAbbreviatedDayName(DateTime dateTime) 699private String GetEra(DateTime dateTime) 763private DateTime EffectiveVisibleDate(DateTime visibleDate) 772private DateTime FirstCalendarDay(DateTime visibleDate) 774DateTime firstDayOfMonth = EffectiveVisibleDate(visibleDate); 841DateTime beginDate = EffectiveVisibleDate(Control.VisibleDate); 844DateTime endDate = _threadCalendar.AddMonths(beginDate, 1); 863DateTime tempDate = FirstCalendarDay(Control.VisibleDate); 870DateTime endDate = _threadCalendar.AddDays(Control.VisibleDate, 6); 893private void SelectRange(DateTime dateFrom, DateTime dateTo)
UI\MobileControls\Adapters\XhtmlAdapters\XhtmlBasicCalendarAdapter.cs (22)
143if (Page.IsPostBack && Control.VisibleDate == DateTime.MinValue) { 144Control.VisibleDate = DateTime.Today; 207DateTime visibleDate = Control.VisibleDate; 209bool saveVisibleDate = visibleDate != DateTime.MinValue && 210DateTime.Compare(visibleDate, DateTime.Today) != 0 && 292DateTime tempDate; 550DateTime dateTime = DateTime.ParseExact(dateText, dateFormat, null); 639private String GetAbbreviatedDayName(DateTime dateTime) { 644private String GetEra(DateTime dateTime) { 699private DateTime EffectiveVisibleDate(DateTime visibleDate) { 707private DateTime FirstCalendarDay(DateTime visibleDate) { 708DateTime firstDayOfMonth = EffectiveVisibleDate(visibleDate); 771DateTime beginDate = EffectiveVisibleDate(Control.VisibleDate); 774DateTime endDate = _threadCalendar.AddMonths(beginDate, 1); 791DateTime tempDate = FirstCalendarDay(Control.VisibleDate); 797DateTime endDate = _threadCalendar.AddDays(Control.VisibleDate, 6); 818private void SelectRange(DateTime dateFrom, DateTime dateTo) {
UI\MobileControls\Adapters\XhtmlAdapters\XhtmlBasicPageAdapter.cs (1)
405Page.Cache.Insert(writer.CacheKey, writer.GetStyles (), null, DateTime.MaxValue, _cacheExpirationTime);
UI\MobileControls\Calendar.cs (4)
124DefaultValue(typeof(DateTime), "1/1/0001"), 127public DateTime SelectedDate 193DefaultValue(typeof(DateTime), "1/1/0001"), 196public DateTime VisibleDate
UI\MobileControls\Design\CalendarDataBindingHandler.cs (1)
32calendar.SelectedDate = DateTime.Today;
UI\MobileControls\MobilePage.cs (1)
555long ticks = DateTime.Now.Ticks % 999983;
UI\MobileControls\ObjectList.cs (1)
889(type == typeof(DateTime)) ||
UI\MobileControls\SessionViewState.cs (5)
187private DateTime _sessionUniqueID = DateTime.Now; 224DateTime uniqueID = (DateTime) id.First; 225if (DateTime.Compare(uniqueID, _sessionUniqueID) != 0)
System.Web.Services (4)
System\Web\Services\Protocols\Scalars.cs (1)
70type == typeof(DateTime) ||
System\Web\Services\Protocols\SoapServerProtocol.cs (2)
277Int64 nowTicks = DateTime.UtcNow.Ticks; 900if (DateTime.UtcNow.Ticks > readerTimedout) {
System\Web\Services\Protocols\WebServiceHandler.cs (1)
63context.Response.Cache.SetExpires(DateTime.Now.AddSeconds(cacheDuration));
System.Windows.Forms (182)
parent\parent\parent\public\Internal\NDP\Inc\IsolationInterop.cs (1)
1367public StoreOperationPinDeployment(IDefinitionAppId AppId, System.DateTime Expiry, StoreApplicationReference Ref)
parent\parent\parent\public\Internal\NDP\Inc\mansign.cs (3)
1416private DateTime m_timestampTime; 1425m_timestampTime = DateTime.FromFileTime(dt); 1443internal DateTime TimestampTime {
parent\parent\parent\public\Internal\NDP\Inc\mansign2.cs (6)
254DateTime verificationTime; 396DateTime verificationTime; 761private bool VerifySignatureTimestamp(XmlElement signatureNode, XmlNamespaceManager nsm, out DateTime verificationTime) 763verificationTime = DateTime.Now; 817private bool VerifySignatureTimestampNew(XmlElement signatureNode, XmlNamespaceManager nsm, out DateTime verificationTime) 819verificationTime = DateTime.Now;
winforms\Managed\System\WinForms\AxHost.cs (6)
3670private DateTime val; 3674val = DateTime.Parse(timestamp, CultureInfo.InvariantCulture); 3678public DateTime Value { 5028protected static double GetOADateFromTime(DateTime time) { 5037protected static DateTime GetTimeFromOADate(double date) { 5038return DateTime.FromOADate(date);
winforms\Managed\System\WinForms\ComboBox.cs (6)
2229this.autoCompleteTimeStamp = DateTime.Now.Ticks; 2240if (DateTime.Now.Ticks - this.autoCompleteTimeStamp > AutoCompleteTimeout || 2253this.autoCompleteTimeStamp = DateTime.Now.Ticks; 2265if (DateTime.Now.Ticks - this.autoCompleteTimeStamp > AutoCompleteTimeout) { 2271this.autoCompleteTimeStamp = DateTime.Now.Ticks; 2284this.autoCompleteTimeStamp = DateTime.Now.Ticks;
winforms\Managed\System\WinForms\ComponentModel\COM2Interop\COM2Properties.cs (3)
133touchedTime = DateTime.Now.Ticks; 204return DateTime.Now.Ticks - touchedTime; 218touchedTime = DateTime.Now.Ticks;
winforms\Managed\System\WinForms\ComponentModel\COM2Interop\COM2TypeInfoProcessor.cs (1)
977return typeof(DateTime);
winforms\Managed\System\WinForms\DataGridTable.cs (1)
1466else if (dataType.Equals(typeof(DateTime)))
winforms\Managed\System\WinForms\DataGridViewMethods.cs (2)
5835(DateTime.Now.Ticks - this.lastMouseClickInfo.timeStamp) / 10000 <= SystemInformation.DoubleClickTime && 25558this.lastMouseClickInfo.timeStamp = DateTime.Now.Ticks;
winforms\Managed\System\WinForms\DateBoldEvent.cs (3)
26readonly DateTime startDate; //the starting date 30internal DateBoldEventArgs(DateTime start, int size) { 38public DateTime StartDate {
winforms\Managed\System\WinForms\DateRangeEvent.cs (6)
24readonly DateTime start; // The date for the first day in the user's selection range. 25readonly DateTime end; // The date for the last day in the user's selection range. 31public DateRangeEventArgs(DateTime start, DateTime end) { 40public DateTime Start { 47public DateTime End {
winforms\Managed\System\WinForms\DateTimePicker.cs (35)
80public static readonly DateTime MinDateTime = new DateTime(1753, 1, 1); 87public static readonly DateTime MaxDateTime = new DateTime(9998, 12, 31); 102private DateTime value = DateTime.Now; 103private DateTime creationTime = DateTime.Now; 105private DateTime max = DateTime.MaxValue; 106private DateTime min = DateTime.MinValue; 683static internal DateTime EffectiveMinDate(DateTime minDate) 685DateTime minSupportedDate = DateTimePicker.MinimumDateTime; 697static internal DateTime EffectiveMaxDate(DateTime maxDate) 699DateTime maxSupportedDate = DateTimePicker.MaximumDateTime; 718public DateTime MaxDate { 750public static DateTime MaximumDateTime { 752DateTime maxSupportedDateTime = CultureInfo.CurrentCulture.Calendar.MaxSupportedDateTime; 770public DateTime MinDate { 810public static DateTime MinimumDateTime { 812DateTime minSupportedDateTime = CultureInfo.CurrentCulture.Calendar.MinSupportedDateTime; 978Value = DateTime.Parse(value, CultureInfo.CurrentCulture); 1005public DateTime Value { 1014bool valueChanged = !DateTime.Equals(this.Value, value); 1138creationTime = DateTime.Now; 1180private static string FormatDateTime(DateTime value) { 1366this.value = DateTime.Now; 1432private void SetRange(DateTime min, DateTime max) { 1529return max != MaximumDateTime && max != DateTime.MaxValue; 1536return min != MinimumDateTime && min != DateTime.MinValue; 1613DateTime temp = value; 1711internal static NativeMethods.SYSTEMTIME DateTimeToSysTime(DateTime time) { 1728internal static DateTime SysTimeToDateTime(NativeMethods.SYSTEMTIME s) {
winforms\Managed\System\WinForms\ListView.cs (1)
3245rnd = new Random((int)System.DateTime.Now.Ticks);
winforms\Managed\System\WinForms\MonthCalendar.cs (75)
131private DateTime maxDate = DateTime.MaxValue; 132private DateTime minDate = DateTime.MinValue; 135private DateTime todayDate = DateTime.Now.Date; 136private DateTime selectionStart; 137private DateTime selectionEnd; 268public DateTime[] AnnuallyBoldedDates { 270DateTime[] dateTimes = new DateTime[annualArrayOfDates.Count]; 273dateTimes[i] = (DateTime)this.annualArrayOfDates[i]; 382public DateTime[] BoldedDates { 384DateTime[] dateTimes = new DateTime[arrayOfDates.Count]; 387dateTimes[i] = (DateTime)this.arrayOfDates[i]; 578public DateTime MaxDate { 633public DateTime MinDate { 663public DateTime[] MonthlyBoldedDates { 665DateTime[] dateTimes = new DateTime[monthlyArrayOfDates.Count]; 668dateTimes[i] = (DateTime)this.monthlyArrayOfDates[i]; 700private DateTime Now { 702return DateTime.Now.Date; 806public DateTime SelectionEnd { 849public DateTime SelectionStart { 1054public DateTime TodayDate { 1066if (!(todayDateSet) || (DateTime.Compare(value, todayDate) != 0)) { 1069if (DateTime.Compare(value, maxDate) > 0) { 1074if (DateTime.Compare(value, minDate) < 0) { 1178public void AddAnnuallyBoldedDate(DateTime date) { 1188public void AddBoldedDate(DateTime date) { 1199public void AddMonthlyBoldedDate(DateTime date) { 1337DateTime date = (DateTime) arrayOfDates[i]; 1338if (DateTime.Compare(date, range.Start) >= 0 && DateTime.Compare(date, range.End) <= 0) { 1356private bool CompareDayAndMonth(DateTime t1, DateTime t2) { 1397private static string FormatDate(DateTime value) { 1476textExtent = WindowsGraphicsCacheManager.MeasurementGraphics.GetTextExtent(DateTime.Now.ToShortDateString(), font); 1780public void RemoveAnnuallyBoldedDate(DateTime date) { 1784if (CompareDayAndMonth((DateTime) annualArrayOfDates[i], date)) { 1791if (CompareDayAndMonth((DateTime) annualArrayOfDates[j], date)) { 1805public void RemoveBoldedDate(DateTime date) { 1808if (DateTime.Compare( ((DateTime)arrayOfDates[i]).Date, date.Date) == 0) { 1824public void RemoveMonthlyBoldedDate(DateTime date) { 1828if (CompareDayAndMonth((DateTime) monthlyArrayOfDates[i], date)) { 1835if (CompareDayAndMonth((DateTime) monthlyArrayOfDates[j], date)) { 1860MaxDate = DateTime.MaxValue; 1869MinDate = DateTime.MinValue; 1993private void SetRange(DateTime minDate, DateTime maxDate) { 2070public void SetDate(DateTime date) { 2088public void SetSelectionRange(DateTime date1, DateTime date2) { 2136private void SetSelRange(DateTime lower, DateTime upper) { 2204return maxDate != DateTimePicker.MaximumDateTime && maxDate != DateTime.MaxValue; 2212return minDate != DateTimePicker.MinimumDateTime && minDate != DateTime.MinValue; 2220return !DateTime.Equals(selectionEnd, selectionStart); 2291DateTime start = selectionStart = DateTimePicker.SysTimeToDateTime(nmmcsc.stSelStart); 2292DateTime end = selectionEnd = DateTimePicker.SysTimeToDateTime(nmmcsc.stSelEnd); 2315DateTime start = DateTimePicker.SysTimeToDateTime(nmmcds.stStart); 2351DateTime start = selectionStart = DateTimePicker.SysTimeToDateTime(nmmcsc.stSelStart); 2352DateTime end = selectionEnd = DateTimePicker.SysTimeToDateTime(nmmcsc.stSelEnd); 2474readonly DateTime time; 2480internal HitTestInfo(Point pt, HitArea area, DateTime time) { 2518public DateTime Time { 2691if (System.DateTime.Equals(calendar.SelectionStart.Date, calendar.SelectionEnd.Date)) { 2699if (System.DateTime.Equals(this.calendar.SelectionStart.Month, this.calendar.SelectionEnd.Month)) { 2707if (System.DateTime.Equals(calendar.SelectionStart.Year, calendar.SelectionEnd.Year)) { 2728if (System.DateTime.Equals(calendar.SelectionStart.Date, calendar.SelectionEnd.Date)) { 2736if (System.DateTime.Equals(this.calendar.SelectionStart.Month, this.calendar.SelectionEnd.Month)) {
winforms\Managed\System\WinForms\NativeMethods.cs (1)
4349else if (t == typeof(DateTime)) {
winforms\Managed\System\WinForms\NumericUpDown.cs (2)
630long nowTicks = DateTime.Now.Ticks; 693this.buttonPressedStartTime = DateTime.Now.Ticks;
winforms\Managed\System\WinForms\PropertyGrid.cs (1)
5399Random rnd = new Random(DateTime.Now.Millisecond);
winforms\Managed\System\WinForms\PropertyGridInternal\PropertyGridView.cs (2)
2806long timeStamp = DateTime.Now.Ticks; 3648rowSelectTime = DateTime.Now.Ticks;
winforms\Managed\System\WinForms\SelectionRange.cs (8)
32private DateTime start = DateTime.MinValue.Date; 38private DateTime end = DateTime.MaxValue.Date; 51public SelectionRange(DateTime lower, DateTime upper) { 81public DateTime End { 94public DateTime Start {
winforms\Managed\System\WinForms\SelectionRangeConverter.cs (17)
37if (sourceType == typeof(string) || sourceType == typeof(DateTime)) { 49if (destinationType == typeof(InstanceDescriptor) || destinationType == typeof(DateTime)) { 63return new SelectionRange(DateTime.Now.Date, DateTime.Now.Date); 75TypeConverter dateTimeConverter = TypeDescriptor.GetConverter(typeof(DateTime)); 76DateTime start = (DateTime)dateTimeConverter.ConvertFromString(context, culture, tokens[0]); 77DateTime end = (DateTime)dateTimeConverter.ConvertFromString(context, culture, tokens[1]); 86else if (value is DateTime) { 87DateTime dt = (DateTime)value; 125if (destinationType == typeof(DateTime)) { 130typeof(DateTime), typeof(DateTime)}); 148return new SelectionRange((DateTime)propertyValues["Start"], 149(DateTime)propertyValues["End"]);
winforms\Managed\System\WinForms\ToolStripItem.cs (1)
2957long newTime = DateTime.Now.Ticks;
winforms\Managed\System\WinForms\ToolStripSplitButton.cs (1)
560long newTime = DateTime.Now.Ticks;
System.Windows.Forms.DataVisualization (104)
Common\Converters\AxisConverters.cs (6)
124 return DateTime.FromOADate((double)value).ToShortDateString(); 126 return DateTime.FromOADate((double)value).ToString("g", System.Globalization.CultureInfo.CurrentCulture); 209DateTime valueAsDate; 210bool parseSucceed = DateTime.TryParse(stringValue, CultureInfo.InvariantCulture, DateTimeStyles.None, out valueAsDate); 425DateTime valueAsDate; 426bool parseSucceed = DateTime.TryParse(stringValue, CultureInfo.CurrentCulture, DateTimeStyles.None, out valueAsDate);
Common\Converters\DataManagerConverters.cs (8)
524DateTime valueAsDate; 525if (DateTime.TryParse(values[index], CultureInfo.InvariantCulture, DateTimeStyles.None, out valueAsDate)) 529else if (DateTime.TryParse(values[index], CultureInfo.CurrentCulture, DateTimeStyles.None, out valueAsDate)) 589 result += DateTime.FromOADate(d).ToString("g", System.Globalization.CultureInfo.InvariantCulture) + ","; 630 DateTime valueAsSate = DateTime.FromOADate((double)value); 656DateTime valueAsSate = DateTime.Parse(stringValue, System.Globalization.CultureInfo.CurrentCulture);
Common\DataManager\DataPoint.cs (31)
1005if (yValue[0] is DateTime) 1057 if(xValue is DateTime) 1077if (yValue[0] is DateTime) 1512 if(columnDataType == typeof(DateTime)) 1928 if(obj is DateTime) 1930 doubleObj = ((DateTime)obj).ToOADate(); 2114 else if(paramType == typeof(DateTime)) 2116 this._xValue = ((DateTime)xValue).ToOADate(); 2124 if(base.series != null && xValue is DateTime) 2128 DateTime time = new DateTime( 2129 ((DateTime)xValue).Year, 2130 ((DateTime)xValue).Month, 2131 ((DateTime)xValue).Day, 2140 DateTime time = new DateTime( 2144 ((DateTime)xValue).Hour, 2145 ((DateTime)xValue).Minute, 2146 ((DateTime)xValue).Second, 2147 ((DateTime)xValue).Millisecond); 2244 else if(paramType == typeof(DateTime)) 2251 this._yValue[i] = DateTime.Now.ToOADate(); 2255 this._yValue[i] = ((DateTime)yValue[i]).ToOADate(); 2288 DateTime yDate; 2289 if (yValue[i] is DateTime) 2290 yDate = (DateTime)yValue[i]; 2292 yDate = DateTime.FromOADate((Double)yValue[i]); 2296 DateTime date = new DateTime( 2309 DateTime yTime; 2310 if (yValue[i] is DateTime) 2311 yTime = (DateTime)yValue[i]; 2313 yTime = DateTime.FromOADate((Double)yValue[i]); 2317 DateTime time = new DateTime(
Common\DataManager\DataSeries.cs (15)
925 type == typeof(DateTime) || 996DateTime[] dateValues = { DateTime.Now.Date, DateTime.Now.Date.AddDays(1), DateTime.Now.Date.AddDays(2), DateTime.Now.Date.AddDays(3), DateTime.Now.Date.AddDays(4), DateTime.Now.Date.AddDays(4) }; 1026dateValues = new DateTime[] { DateTime.Now, DateTime.Now.AddMinutes(1), DateTime.Now.AddMinutes(2), DateTime.Now.AddMinutes(3), DateTime.Now.AddMinutes(4), DateTime.Now.AddMinutes(4) };
Common\General\AxisScale.cs (4)
1374 DateTime dateTimeMin = DateTime.FromOADate( min ); 1375 DateTime dateTimeMax = DateTime.FromOADate( max );
Common\General\AxisScrollZoom.cs (5)
1648strValue = DateTime.FromOADate(dtValue).ToString("g", System.Globalization.CultureInfo.CurrentCulture); 1658strValue = DateTime.FromOADate(dtValue).ToShortDateString(); 1662strValue = DateTime.FromOADate(dtValue).ToString("g", System.Globalization.CultureInfo.CurrentCulture); 1752DateTime valueAsDate; 1753bool parseSucceed = DateTime.TryParse(crossingValue, CultureInfo.InvariantCulture, DateTimeStyles.None, out valueAsDate);
Common\General\Chart.cs (1)
876 yValuesObj[i] = (((Series)seriesList[0]).IsYValueDateTime()) ? DateTime.Now.Date.ToOADate() : 0.0;
Common\General\ChartAreaAxes.cs (4)
1968 DateTime date1 = DateTime.FromOADate(value1); 1969 DateTime date2 = DateTime.FromOADate(value2);
Common\General\ChartElement.cs (11)
977 DateTime newStartDate = DateTime.FromOADate(start); 986 DateTime resultDate = newStartDate; 987 DateTime sizeAdjustedDate = new DateTime(newStartDate.Year, 1, 1, 0, 0, 0); 1197 DateTime dateValue = DateTime.FromOADate(series.Points[pointIndex].XValue); 1198 DateTime roundedDateValue = dateValue; 1284 DateTime date = DateTime.FromOADate(current); 1316 if(date.Day == DateTime.DaysInMonth(date.Year, date.Month)) 1329 int daysInMobth = DateTime.DaysInMonth(date.Year, date.Month);
Common\General\DataManipulator.cs (6)
975 columnType = typeof(DateTime); 990 columnType = typeof(DateTime); 1026xValue = DateTime.FromOADate(point.XValue); 1045yValue = DateTime.FromOADate(point.YValues[yIndex]); 1618 DateTime dateTimeValue = DateTime.FromOADate(point.XValue);
Common\General\Label.cs (8)
290labelEnd = DateTime.FromOADate(labelStart).AddMilliseconds(labelsStep).ToOADate(); 294labelEnd = DateTime.FromOADate(labelStart).AddSeconds(labelsStep).ToOADate(); 298labelEnd = DateTime.FromOADate(labelStart).AddMinutes(labelsStep).ToOADate(); 302labelEnd = DateTime.FromOADate(labelStart).AddHours(labelsStep).ToOADate(); 306labelEnd = DateTime.FromOADate(labelStart).AddDays(labelsStep).ToOADate(); 310labelEnd = DateTime.FromOADate(labelStart).AddDays(7 * labelsStep).ToOADate(); 314labelEnd = DateTime.FromOADate(labelStart).AddMonths((int)labelsStep).ToOADate(); 318labelEnd = DateTime.FromOADate(labelStart).AddYears((int)labelsStep).ToOADate();
Common\Utilities\ValueConverter.cs (2)
120result = String.Format(CultureInfo.CurrentCulture, convertionFormat, DateTime.FromOADate(value)); 131result = String.Format(CultureInfo.CurrentCulture, convertionFormat, DateTime.FromOADate(value));
Common\Utilities\XmlSerializer.cs (3)
2715 else if(obj is DateTime) 2718 writer.Write(((DateTime)obj).Ticks); 3127 else if(pi.PropertyType == typeof(DateTime))
System.Workflow.Activities (2)
Delay.cs (2)
309DateTime timeOut = DateTime.UtcNow + timeSpan;
System.Workflow.ComponentModel (22)
AuthoringOM\ActivityInterfaces.cs (1)
173void ScheduleTimer(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId);
AuthoringOM\Compiler\TypeSystem\RTTypeWrapper.cs (1)
593returnType = typeof(DateTime?);
AuthoringOM\Design\Dialogs\ActivityBindForm.cs (1)
764return type.IsPrimitive || type.IsEnum || type == typeof(Guid) || type == typeof(IntPtr) || type == typeof(string) || type == typeof(DateTime) || type == typeof(TimeSpan);
AuthoringOM\Design\WorkflowLayouts.cs (3)
348private DateTime previewTime = DateTime.Now; 778this.previewTime = DateTime.Now;
AuthoringOM\Design\WorkflowPrinting.cs (3)
40private DateTime printTime; //when the document started to print 364this.printTime = DateTime.Now; 385internal DateTime PrintTime;
AuthoringOM\Serializer\WorkflowMarkupSerializer.cs (13)
303obj.GetType().IsEnum || obj.GetType() == typeof(DateTime) || obj.GetType() == typeof(TimeSpan) || 641obj.GetType() == typeof(DateTime) || obj.GetType() == typeof(TimeSpan) || obj.GetType().IsEnum || 646obj.GetType() == typeof(DateTime) || obj.GetType() == typeof(TimeSpan) || 654if (obj.GetType() == typeof(DateTime)) 656stringValue = ((DateTime)obj).ToString("o", CultureInfo.InvariantCulture); 1185|| valueType == typeof(TimeSpan) || valueType == typeof(Guid) || valueType == typeof(DateTime)) 1200else if (typeof(DateTime).IsAssignableFrom(value.GetType())) 1201return ((DateTime)value).ToString("o", CultureInfo.InvariantCulture); 1259else if (typeof(DateTime) == propertyType) 1261propVal = DateTime.Parse(value, CultureInfo.InvariantCulture, DateTimeStyles.RoundtripKind); 1738if (type.IsPrimitive || type == typeof(string) || type == typeof(decimal) || type == typeof(DateTime) || 1744if (type == typeof(DateTime)) 1746obj = DateTime.Parse(stringValue, CultureInfo.InvariantCulture, DateTimeStyles.RoundtripKind);
System.Workflow.Runtime (145)
Hosting\DefaultWorkflowSchedulerService.cs (10)
17private KeyedPriorityQueue<Guid, CallbackInfo, DateTime> timerQueue = new KeyedPriorityQueue<Guid, CallbackInfo, DateTime>(); 109internal protected override void Schedule(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId) 111WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "Scheduling work for instance {0} on timer ID {1} in {2}", workflowInstanceId, timerId, (whenUtc - DateTime.UtcNow)); 254DateTime now = DateTime.UtcNow; 354DateTime when; 357public CallbackInfo(WorkflowSchedulerService service, WaitCallback callback, object state, DateTime when) 365public DateTime When 372get { return DateTime.UtcNow >= when; }
Hosting\ManualWorkflowSchedulerService.cs (10)
20DateTime when; 22public CallbackInfo(WaitCallback callback, Guid instanceId, Guid timerId, DateTime when) 30public DateTime When 37get { return DateTime.UtcNow >= when; } 50private KeyedPriorityQueue<Guid, CallbackInfo, DateTime> pendingScheduleRequests = new KeyedPriorityQueue<Guid, CallbackInfo, DateTime>(); 125internal protected override void Schedule(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId) 192CallbackInfo ci = pendingScheduleRequests.FindByPriority(DateTime.UtcNow, 263DateTime now = DateTime.UtcNow;
Hosting\SqlWorkflowPersistenceService.cs (35)
114WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService OpenConnection start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 116WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService. OpenConnection end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 160public void InsertInstanceState(PendingWorkItem item, Guid ownerId, DateTime ownedUntil) 182command.Parameters.Add(this.dbResourceAllocator.NewDbParameter("@ownedUntil", ownedUntil == DateTime.MaxValue ? SqlDateTime.MaxValue : ownedUntil)); 243public IList<Guid> RetrieveNonblockingInstanceStateIds(Guid ownerId, DateTime ownedUntil) 258command.Parameters.Add(this.dbResourceAllocator.NewDbParameter("@ownedUntil", ownedUntil == DateTime.MaxValue ? SqlDateTime.MaxValue : ownedUntil)); 260command.Parameters.Add(this.dbResourceAllocator.NewDbParameter("@now", DateTime.UtcNow)); 262WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.RetrieveNonblockingInstanceStateIds ExecuteReader start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 264WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.RetrieveNonblockingInstanceStateIds ExecuteReader end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 294public bool TryRetrieveANonblockingInstanceStateId(Guid ownerId, DateTime ownedUntil, out Guid instanceId) 307command.Parameters.Add(this.dbResourceAllocator.NewDbParameter("@ownedUntil", ownedUntil == DateTime.MaxValue ? SqlDateTime.MaxValue : ownedUntil)); 325WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.TryRetrieveANonblockingInstanceStateId ExecuteNonQuery start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 327WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.TryRetrieveANonblockingInstanceStateId ExecuteNonQuery end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 356public IList<Guid> RetrieveExpiredTimerIds(Guid ownerId, DateTime ownedUntil) 372command.Parameters.Add(this.dbResourceAllocator.NewDbParameter("@ownedUntil", ownedUntil == DateTime.MaxValue ? SqlDateTime.MaxValue : ownedUntil)); 374command.Parameters.Add(this.dbResourceAllocator.NewDbParameter("@now", DateTime.UtcNow)); 376WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.RetrieveExpiredTimerIds ExecuteReader start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 378WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.RetrieveExpiredTimerIds ExecuteReader end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 408public Byte[] RetrieveInstanceState(Guid instanceStateId, Guid ownerId, DateTime timeout) 424command.Parameters.Add(this.dbResourceAllocator.NewDbParameter("@ownedUntil", timeout == DateTime.MaxValue ? SqlDateTime.MaxValue : timeout)); 605WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.RetrieveStateFromDB {0} ExecuteReader start: {1}", instanceId, DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 607WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlWorkflowPersistenceService.RetrieveStateFromDB {0} ExecuteReader end: {1}", instanceId, DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 724private DateTime OwnershipTimeout 728DateTime timeout; 730timeout = DateTime.MaxValue; 732timeout = DateTime.UtcNow + _ownershipDelta; 1177loadingTimer.Update((DateTime)item.NextTimer); 1191private DateTime next; 1202this.next = DateTime.UtcNow + due; 1206public void Update(DateTime newNext) 1208if (newNext < next && (next - DateTime.UtcNow) > minUpdate) 1212if (newNext < next && (next - DateTime.UtcNow) > minUpdate && timer != null) 1216TimeSpan when = next - DateTime.UtcNow; 1238next = DateTime.UtcNow + period; 1241TimeSpan when = next - DateTime.UtcNow;
Hosting\WorkflowPersistenceService.cs (6)
49DateTime startTime = DateTime.Now; 65TimeSpan timeElapsed = DateTime.Now - startTime; 79DateTime startTime = DateTime.Now; 90TimeSpan timeElapsed = DateTime.Now - startTime;
Hosting\WorkflowSchedulerService.cs (1)
10internal protected abstract void Schedule(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId);
Hosting\WorkflowTimerService.cs (1)
17public void ScheduleTimer(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId)
System\Activities\Statements\InteropEnvironment.cs (2)
117DateTime.UtcNow, 134DateTime.UtcNow,
System\Activities\Statements\InteropExecutor.cs (2)
1026public void ScheduleTimer(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId) 1033TimeSpan timerDuration = whenUtc - DateTime.UtcNow;
TimerEventSubscription.cs (4)
16DateTime expiresAt; 26public virtual DateTime ExpiresAt 78public TimerEventSubscription(Guid workflowInstanceId, DateTime expiresAt) 91public TimerEventSubscription(Guid timerId, Guid workflowInstanceId, DateTime expiresAt)
TimerEventSubscriptionCollection.cs (2)
21private KeyedPriorityQueue<Guid, TimerEventSubscription, DateTime> queue = new KeyedPriorityQueue<Guid, TimerEventSubscription, DateTime>();
Tracking.cs (10)
638DateTime dt = DateTime.UtcNow; 666DateTime dt = DateTime.UtcNow; 806DateTime dt = DateTime.UtcNow; 829DateTime dt = DateTime.UtcNow; 1532internal DateTime LastAccess = DateTime.UtcNow;
Tracking\SqlTrackingQuery.cs (9)
195if (DateTime.MinValue != opt.StatusMinDateTime || DateTime.MaxValue != opt.StatusMaxDateTime) 286private DateTime _min = DateTime.MinValue, _max = DateTime.MaxValue; 301public DateTime StatusMinDateTime 306public DateTime StatusMaxDateTime 318_min = DateTime.MinValue; 319_max = DateTime.MaxValue;
Tracking\SqlTrackingService.cs (14)
42private DateTime _lastProfileCheck; 187_lastProfileCheck = DateTime.UtcNow; 438_lastProfileCheck = (DateTime)cmd.Parameters[1].Value; 462WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteRetried " + executeRetried.Method.Name + " start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 464WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteRetried " + executeRetried.Method.Name + " end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 492WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteReaderRetried ExecuteReader start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 494WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteReaderRetried ExecuteReader end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 523WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteNonQueryRetried ExecuteNonQuery start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 525WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteNonQueryRetried ExecuteNonQuery end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 554WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteNonQueryWithTxRetried ExecuteNonQuery start: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 558WorkflowTrace.Host.TraceEvent(TraceEventType.Information, 0, "SqlTrackingService.ExecuteNonQueryWithTxRetried ExecuteNonQuery end: " + DateTime.UtcNow.ToString("G", System.Globalization.CultureInfo.InvariantCulture)); 870command.Parameters.Add(DbResourceAllocator.NewDbParameter("@EndDateTime", DateTime.UtcNow)); 1259command.Parameters.Add(DbResourceAllocator.NewDbParameter("@EventDateTime", this.GetSqlDateTimeString(DateTime.UtcNow))); 2188private string GetSqlDateTimeString(DateTime dateTime)
Tracking\SqlTrackingWorkflowInstance.cs (22)
33DateTime _currDT = DateTime.UtcNow, 44DateTime _initialized; 92public DateTime Initialized 190_currDT = DateTime.UtcNow; 213DateTime tmpMin = SqlDateTime.MinValue.Value; 218DateTime dt = reader.GetDateTime(2); 228DateTime dbDt = reader.GetDateTime(9); 349DateTime tmpMin = SqlDateTime.MinValue.Value; 353DateTime dt = reader.GetDateTime(1); 375DateTime dbDt = reader.GetDateTime(11); 490DateTime tmpMin = SqlDateTime.MinValue.Value; 496DateTime dt = reader.GetDateTime(1); 510DateTime dbDt = reader.GetDateTime(5); 618DateTime currDT = DateTime.MinValue; 624DateTime dt = reader.GetDateTime(1); 721DateTime tmpDT = _changesMinDT; 785DateTime tmpMin = SqlDateTime.MinValue.Value; 842private SqlCommand CreateInternalIdDateTimeCommand(string commandText, DateTime minDT) 847private SqlCommand CreateInternalIdDateTimeCommand(string commandText, DateTime minDT, DateTime maxDT)
Tracking\TrackingRecord.cs (13)
18public abstract DateTime EventDateTime 56private DateTime _eventDateTime = DateTime.MinValue; 69public ActivityTrackingRecord(Type activityType, string qualifiedName, Guid contextGuid, Guid parentContextGuid, ActivityExecutionStatus executionStatus, DateTime eventDateTime, int eventOrder, EventArgs eventArgs) 124public override DateTime EventDateTime 163private DateTime _eventDateTime = DateTime.MinValue; 178public UserTrackingRecord(Type activityType, string qualifiedName, Guid contextGuid, Guid parentContextGuid, DateTime eventDateTime, int eventOrder, string userDataKey, object userData) 239public override DateTime EventDateTime 274private DateTime _eventDateTime = DateTime.MinValue; 287public WorkflowTrackingRecord(TrackingWorkflowEvent trackingWorkflowEvent, DateTime eventDateTime, int eventOrder, EventArgs eventArgs) 305public override DateTime EventDateTime
WorkflowExecutor.cs (3)
683if (sub == null || sub.ExpiresAt > DateTime.UtcNow) 1365internal DateTime GetWorkflowNextTimerExpiration() 1373return sub == null ? DateTime.MaxValue : sub.ExpiresAt;
WorkflowInstance.cs (1)
90public DateTime GetWorkflowNextTimerExpiration()
System.WorkflowServices (6)
System\ServiceModel\Security\SerializableAuthorizationContext.cs (5)
31DateTime expirationTime; 35SerializableAuthorizationContext(byte[] contextBlob, DateTime expirationTime, string id, IList<Type> knownTypes) 137static IAuthorizationPolicy RetrievePolicyFromBlob(byte[] contextBlob, string id, DateTime expirationTime, IList<Type> knownTypes) 200DateTime expirationTime; 204public SctUnconditionalPolicy(IList<IIdentity> identities, string id, IList<ClaimSet> claimSets, DateTime expirationTime)
System\Workflow\Runtime\Hosting\SynchronizationContextWorkflowSchedulerService.cs (1)
36protected internal override void Schedule(WaitCallback callback, Guid workflowInstanceId, DateTime whenUtc, Guid timerId)
System.Xml (271)
System\Xml\BinaryXml\SqlUtils.cs (21)
753public static DateTime XsdDateTimeToDateTime(long val) { 767public static DateTime XsdDateToDateTime(long val) { 770DateTime d = new DateTime(yr, mnth, day, 0, 0, 0, DateTimeKind.Utc); 784public static DateTime XsdTimeToDateTime(long val) { 791DateTime dateTime = SqlDateTimeToDateTime(dateticks, timeticks); 795public static DateTime SqlDateTimeToDateTime(int dateticks, uint timeticks) { 796DateTime SQLBaseDate = new DateTime(1900, 1, 1); 812DateTime dateTime = SqlSmallDateTimeToDateTime(dateticks, timeticks); 815public static DateTime SqlSmallDateTimeToDateTime(short dateticks, ushort timeticks) { 820public static DateTime XsdKatmaiDateToDateTime(byte[] data, int offset) { 823DateTime dt = new DateTime(dateTicks); 827public static DateTime XsdKatmaiDateTimeToDateTime(byte[] data, int offset) { 831DateTime dt = new DateTime(dateTicks + timeTicks); 835public static DateTime XsdKatmaiTimeToDateTime(byte[] data, int offset) { 840public static DateTime XsdKatmaiDateOffsetToDateTime( byte[] data, int offset ) { 845public static DateTime XsdKatmaiDateTimeOffsetToDateTime(byte[] data, int offset) { 850public static DateTime XsdKatmaiTimeOffsetToDateTime(byte[] data, int offset) { 893DateTime dt = XsdKatmaiDateToDateTime(data, offset); 900DateTime dt = XsdKatmaiDateTimeToDateTime(data, offset); 909DateTime dt = XsdKatmaiTimeToDateTime(data, offset); 977static int GetFractions(DateTime dt) {
System\Xml\BinaryXml\XmlBinaryReader.cs (4)
1011public override DateTime ReadContentAsDateTime() { 1013DateTime value; 2907Type TypeOfDateTime = typeof(System.DateTime); 3344DateTime ValueAsDateTime() {
System\Xml\Core\XmlAsyncCheckReader.cs (3)
201public override DateTime ReadContentAsDateTime() { 261public override DateTime ReadElementContentAsDateTime() { 266public override DateTime ReadElementContentAsDateTime(string localName, string namespaceURI) {
System\Xml\Core\XmlAsyncCheckWriter.cs (1)
227public override void WriteValue(DateTime value) {
System\Xml\Core\XmlAutoDetectWriter.cs (1)
204public override void WriteValue(DateTime value) {
System\Xml\Core\XmlReader.cs (4)
225public virtual DateTime ReadContentAsDateTime() { 391public virtual DateTime ReadElementContentAsDateTime() { 393DateTime value = ReadContentAsDateTime(); 402public virtual DateTime ReadElementContentAsDateTime(string localName, string namespaceURI) {
System\Xml\Core\XmlSubtreeReader.cs (2)
567public override DateTime ReadContentAsDateTime() { 570DateTime value = reader.ReadContentAsDateTime();
System\Xml\Core\XmlWellFormedWriter.cs (1)
1181public override void WriteValue(DateTime value) {
System\Xml\Core\XmlWrappingWriter.cs (1)
182public override void WriteValue(DateTime value) {
System\Xml\Core\XmlWriter.cs (1)
286public virtual void WriteValue(DateTime value) {
System\Xml\Core\XsdValidatingReader.cs (2)
407public override DateTime ReadContentAsDateTime() { 652public override DateTime ReadElementContentAsDateTime() {
System\Xml\Schema\DataTypeImplementation.cs (9)
1806static readonly Type atomicValueType = typeof(DateTime); 1807static readonly Type listValueType = typeof(DateTime[]); 1844DateTime dateTime1 = (DateTime)value1; 1845DateTime dateTime2 = (DateTime)value2; 1866DateTime dateTimeValue = DateTime.MinValue; 1868dateTimeValue = (DateTime)dateTime;
System\Xml\Schema\FacetChecker.cs (9)
665internal virtual Exception CheckValueFacets(DateTime value, XmlSchemaDatatype datatype) { 1051DateTime dateTimeValue = datatype.ValueConverter.ToDateTime(value); 1055internal override Exception CheckValueFacets(DateTime value, XmlSchemaDatatype datatype) { 1060if (datatype.Compare(value, (DateTime)restriction.MaxInclusive) > 0) { 1066if (datatype.Compare(value, (DateTime)restriction.MaxExclusive) >= 0) { 1072if (datatype.Compare(value, (DateTime)restriction.MinInclusive) < 0) { 1078if (datatype.Compare(value, (DateTime)restriction.MinExclusive) <= 0) { 1094private bool MatchEnumeration(DateTime value, ArrayList enumeration, XmlSchemaDatatype datatype) { 1096if (datatype.Compare(value, (DateTime)enumeration[i]) == 0) {
System\Xml\Schema\XmlAtomicValue.cs (3)
33[FieldOffset(0)] public DateTime dtVal; 76internal XmlAtomicValue(XmlSchemaType xmlType, DateTime value) { 216public override DateTime ValueAsDateTime {
System\Xml\Schema\XmlValueConverter.cs (120)
164public abstract bool ToBoolean(DateTime value); 175public abstract int ToInt32(DateTime value); 186public abstract long ToInt64(DateTime value); 197public abstract decimal ToDecimal(DateTime value); 208public abstract double ToDouble(DateTime value); 219public abstract float ToSingle(DateTime value); 224public abstract DateTime ToDateTime(bool value); 225public abstract DateTime ToDateTime(int value); 226public abstract DateTime ToDateTime(long value); 227public abstract DateTime ToDateTime(decimal value); 228public abstract DateTime ToDateTime(float value); 229public abstract DateTime ToDateTime(double value); 230public abstract DateTime ToDateTime(DateTime value); 231public abstract DateTime ToDateTime(DateTimeOffset value); 232public abstract DateTime ToDateTime(string value); 233public abstract DateTime ToDateTime(object value); 241public abstract DateTimeOffset ToDateTimeOffset(DateTime value); 252public abstract string ToString(DateTime value); 265public abstract object ChangeType(DateTime value, Type destinationType); 354protected static readonly Type DateTimeType = typeof(DateTime); 364public override bool ToBoolean(DateTime value) {return (bool) ChangeType((object) value, BooleanType, null); } 374public override DateTime ToDateTime(bool value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 375public override DateTime ToDateTime(DateTime value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 376public override DateTime ToDateTime(DateTimeOffset value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 377public override DateTime ToDateTime(decimal value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 378public override DateTime ToDateTime(double value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 379public override DateTime ToDateTime(int value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 380public override DateTime ToDateTime(long value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 381public override DateTime ToDateTime(float value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 382public override DateTime ToDateTime(string value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 383public override DateTime ToDateTime(object value) {return (DateTime) ChangeType((object) value, DateTimeType, null); } 386public override DateTimeOffset ToDateTimeOffset(DateTime value) {return (DateTimeOffset) ChangeType((object) value, DateTimeOffsetType, null); } 397public override decimal ToDecimal(DateTime value) {return (decimal) ChangeType((object) value, DecimalType, null); } 408public override double ToDouble(DateTime value) {return (double) ChangeType((object) value, DoubleType, null); } 419public override int ToInt32(DateTime value) {return (int) ChangeType((object) value, Int32Type, null); } 430public override long ToInt64(DateTime value) {return (long) ChangeType((object) value, Int64Type, null); } 441public override float ToSingle(DateTime value) {return (float) ChangeType((object) value, SingleType, null); } 452public override string ToString(DateTime value) {return (string) ChangeType((object) value, StringType, null); } 465public override object ChangeType(DateTime value, Type destinationType) {return (object) ChangeType((object) value, destinationType, null); } 585protected static DateTime StringToDate(string value) { 586return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.Date)); 589protected static DateTime StringToDateTime(string value) { 590return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.DateTime)); 602protected static DateTime StringToGDay(string value) { 603return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.GDay)); 606protected static DateTime StringToGMonth(string value) { 607return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.GMonth)); 610protected static DateTime StringToGMonthDay(string value) { 611return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.GMonthDay)); 614protected static DateTime StringToGYear(string value) { 615return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.GYear)); 618protected static DateTime StringToGYearMonth(string value) { 619return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.GYearMonth)); 685protected static DateTime StringToTime(string value) { 686return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.Time)); 711protected static string DateToString(DateTime value) { 715protected static string DateTimeToString(DateTime value) { 727protected static string GDayToString(DateTime value) { 731protected static string GMonthToString(DateTime value) { 735protected static string GMonthDayToString(DateTime value) { 739protected static string GYearToString(DateTime value) { 743protected static string GYearMonthToString(DateTime value) { 788protected static string TimeToString(DateTime value) { 805internal static DateTime DateTimeOffsetToDateTime(DateTimeOffset value) { 872protected static DateTime UntypedAtomicToDateTime(string value) { 873return (DateTime)(new XsdDateTime(value, XsdDateTimeFlags.AllXsd)); 1416public override DateTime ToDateTime(DateTime value) { 1417return ((DateTime) value); 1420public override DateTime ToDateTime(DateTimeOffset value) { 1424public override DateTime ToDateTime(string value) { 1438public override DateTime ToDateTime(object value) { 1443if (sourceType == DateTimeType) return ((DateTime) value); 1448return (DateTime) ChangeListType(value, DateTimeType, null); 1455public override DateTimeOffset ToDateTimeOffset(DateTime value) { 1483if (sourceType == DateTimeType) return ToDateTimeOffset((DateTime)value); 1530public override string ToString(DateTime value) { 1532case XmlTypeCode.Date: return DateToString((DateTime) value); 1533case XmlTypeCode.Time: return TimeToString((DateTime) value); 1534case XmlTypeCode.GDay: return GDayToString((DateTime) value); 1535case XmlTypeCode.GMonth: return GMonthToString((DateTime) value); 1536case XmlTypeCode.GMonthDay: return GMonthDayToString((DateTime) value); 1537case XmlTypeCode.GYear: return GYearToString((DateTime) value); 1538case XmlTypeCode.GYearMonth: return GYearMonthToString((DateTime) value); 1540return DateTimeToString((DateTime) value); 1566if (sourceType == DateTimeType) return this.ToString((DateTime) value); 1579public override object ChangeType(DateTime value, Type destinationType) { 1583if (destinationType == DateTimeType) return ((DateTime) value); 1584if (destinationType == DateTimeOffsetType) return this.ToDateTimeOffset((DateTime) value); 1585if (destinationType == StringType) return this.ToString((DateTime) value); 1586if (destinationType == XmlAtomicValueType) return (new XmlAtomicValue(SchemaType, (DateTime) value)); 1587if (destinationType == XPathItemType) return (new XmlAtomicValue(SchemaType, (DateTime) value)); 1630if (sourceType == DateTimeType) return (new XmlAtomicValue(SchemaType, (DateTime) value)); 1636if (sourceType == DateTimeType) return (new XmlAtomicValue(SchemaType, (DateTime) value)); 2204public override DateTime ToDateTime(string value) { 2209public override DateTime ToDateTime(object value) { 2216return (DateTime) ChangeTypeWildcardDestination(value, DateTimeType, null); 2346public override string ToString(DateTime value) { 2347return DateTimeToString((DateTime) value); 2380if (sourceType == DateTimeType) return DateTimeToString((DateTime) value); 2415public override object ChangeType(DateTime value, Type destinationType) { 2419if (destinationType == StringType) return DateTimeToString((DateTime) value); 2767public override DateTime ToDateTime(object value) { 2774return (DateTime) ChangeTypeWildcardDestination(value, DateTimeType, null); 2887public override object ChangeType(DateTime value, Type destinationType) { 2891if (destinationType == XmlAtomicValueType) return (new XmlAtomicValue(XmlSchemaType.GetBuiltInSimpleType(XmlTypeCode.DateTime), (DateTime) value)); 2996if (sourceType == DateTimeType) return (new XmlAtomicValue(XmlSchemaType.GetBuiltInSimpleType(XmlTypeCode.DateTime), (DateTime) value)); 3168if (itemTypeDst == DateTimeType) return ToArray<DateTime>(value, nsResolver);
System\Xml\Schema\XsdDateTime.cs (24)
42private DateTime dt; 161public XsdDateTime(DateTime dateTime, XsdDateTimeFlags kinds) { 341public DateTime ToZulu() { 377public static implicit operator DateTime(XsdDateTime xdt) { 378DateTime result; 382result = new DateTime(DateTime.Now.Year, xdt.Month, xdt.Day); 386DateTime currentDateTime = DateTime.Now; 404if (ticks < DateTime.MinValue.Ticks) 408if (ticks < DateTime.MinValue.Ticks) 409ticks = DateTime.MinValue.Ticks; 417if (ticks > DateTime.MaxValue.Ticks) 421if (ticks > DateTime.MaxValue.Ticks) 422ticks = DateTime.MaxValue.Ticks; 434DateTime dt; 439dt = new DateTime( DateTime.Now.Year, xdt.Month, xdt.Day ); 443DateTime currentDateTime = DateTime.Now; 479return DateTime.Compare(left.dt, right.dt); 487return DateTime.Compare(left.GetZuluDateTime(), right.GetZuluDateTime()); 647private DateTime GetZuluDateTime() { 799Parse2Dig(start + Lz__mm_, ref day) && 1 <= day && day <= DateTime.DaysInMonth(leapYear, month) && 823Parse2Dig(start + Lz___, ref day) && 1 <= day && day <= DateTime.DaysInMonth(leapYear, firstMonth) && 843Parse2Dig(start + Lzyyyy_MM_, ref day) && 1 <= day && day <= DateTime.DaysInMonth(year, month);
System\Xml\Serialization\CodeGenerator.cs (2)
1103ConstructorInfo DateTime_ctor = typeof(DateTime).GetConstructor( 1109Ldc(((DateTime)o).Ticks); // ticks
System\Xml\Serialization\PrimitiveXmlSerializers.cs (1)
90WriteElementStringRaw(@"dateTime", @"", FromDateTime(((System.DateTime)o)));
System\Xml\Serialization\Types.cs (6)
460AddPrimitive(typeof(DateTime), "dateTime", "DateTime", TypeFlags.CanBeAttributeValue | TypeFlags.CanBeElementValue | TypeFlags.HasCustomFormatter | TypeFlags.XmlEncodingNotRequired); 469AddPrimitive(typeof(DateTime), "date", "Date", TypeFlags.AmbiguousDataType | TypeFlags.CanBeAttributeValue | TypeFlags.CanBeElementValue | TypeFlags.HasCustomFormatter | TypeFlags.XmlEncodingNotRequired); 470AddPrimitive(typeof(DateTime), "time", "Time", TypeFlags.AmbiguousDataType | TypeFlags.CanBeAttributeValue | TypeFlags.CanBeElementValue | TypeFlags.HasCustomFormatter | TypeFlags.XmlEncodingNotRequired); 556AddSoapEncodedPrimitive(typeof(DateTime), "dateTime", ns, "DateTime", new XmlQualifiedName("string", XmlSchema.Namespace), TypeFlags.CanBeAttributeValue | TypeFlags.CanBeElementValue | TypeFlags.HasCustomFormatter | TypeFlags.XmlEncodingNotRequired); 565AddSoapEncodedPrimitive(typeof(DateTime), "date", ns, "Date", new XmlQualifiedName("string", XmlSchema.Namespace), TypeFlags.AmbiguousDataType | TypeFlags.CanBeAttributeValue | TypeFlags.CanBeElementValue | TypeFlags.HasCustomFormatter | TypeFlags.XmlEncodingNotRequired); 566AddSoapEncodedPrimitive(typeof(DateTime), "time", ns, "Time", new XmlQualifiedName("string", XmlSchema.Namespace), TypeFlags.AmbiguousDataType | TypeFlags.CanBeAttributeValue | TypeFlags.CanBeElementValue | TypeFlags.HasCustomFormatter | TypeFlags.XmlEncodingNotRequired);
System\Xml\Serialization\XmlCodeExporter.cs (4)
253else if (type == typeof(DateTime)) { 254DateTime dt = (DateTime)value; 272initExpression = new CodeObjectCreateExpression(new CodeTypeReference(typeof(DateTime)), new CodeExpression[] {new CodePrimitiveExpression(ticks)});
System\Xml\Serialization\XmlCountingReader.cs (3)
118public override DateTime ReadContentAsDateTime() 168public override DateTime ReadElementContentAsDateTime() 173public override DateTime ReadElementContentAsDateTime(string localName, string namespaceURI)
System\Xml\Serialization\Xmlcustomformatter.cs (15)
45if (type == typeof(DateTime)) { 47return FromDateTime((DateTime)value); 50return FromDate((DateTime)value); 53return FromTime((DateTime)value); 73internal static string FromDate(DateTime value) { 77internal static string FromTime(DateTime value) { 80return XmlConvert.ToString(DateTime.MinValue + value.TimeOfDay, "HH:mm:ss.fffffffZ"); 84return XmlConvert.ToString(DateTime.MinValue + value.TimeOfDay, "HH:mm:ss.fffffffzzzzzz"); 88internal static string FromDateTime(DateTime value) { 323internal static DateTime ToDateTime(string value) { 333internal static DateTime ToDateTime(string value, string[] formats) { 337internal static DateTime ToDate(string value) { 341internal static DateTime ToTime(string value) { 344return DateTime.ParseExact(value, allTimeFormats, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.AllowLeadingWhite | DateTimeStyles.AllowTrailingWhite | DateTimeStyles.NoCurrentDateDefault | DateTimeStyles.RoundtripKind); 348return DateTime.ParseExact(value, allTimeFormats, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.AllowLeadingWhite | DateTimeStyles.AllowTrailingWhite | DateTimeStyles.NoCurrentDateDefault);
System\Xml\Serialization\XmlSerializationReader.cs (12)
334return typeof(DateTime); 338return typeof(DateTime); 340return typeof(DateTime); 401return typeof(DateTime); 405return typeof(DateTime); 407return typeof(DateTime); 728value = default(Nullable<DateTime>); 732value = default(Nullable<DateTime>); 734value = default(Nullable<DateTime>); 1064protected static DateTime ToDateTime(string value) { 1069protected static DateTime ToDate(string value) { 1074protected static DateTime ToTime(string value) {
System\Xml\Serialization\XmlSerializationWriter.cs (5)
111protected static string FromDateTime(DateTime value) { 116protected static string FromDate(DateTime value) { 121protected static string FromTime(DateTime value) { 263value = FromDateTime((DateTime)o); 3115Writer.Write(((DateTime)value).Ticks.ToString(CultureInfo.InvariantCulture));
System\Xml\XmlConvert.cs (15)
756public static string ToString(DateTime value) { 764public static string ToString(DateTime value, string format) { 772public static string ToString(DateTime value, XmlDateTimeSerializationMode dateTimeOption) { 1240public static DateTime ToDateTime(string s) { 1249public static DateTime ToDateTime(string s, string format) { 1250return DateTime.ParseExact(s, format, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.AllowLeadingWhite|DateTimeStyles.AllowTrailingWhite); 1257public static DateTime ToDateTime(string s, string[] formats) { 1258return DateTime.ParseExact(s, formats, DateTimeFormatInfo.InvariantInfo, DateTimeStyles.AllowLeadingWhite|DateTimeStyles.AllowTrailingWhite); 1265public static DateTime ToDateTime(string s, XmlDateTimeSerializationMode dateTimeOption) { 1267DateTime dt = (DateTime)xsdDateTime; 1341private static DateTime SwitchToLocalTime(DateTime value) { 1355private static DateTime SwitchToUtcTime(DateTime value) {
System\Xml\XPath\XPathItem.cs (1)
33public abstract DateTime ValueAsDateTime { get; }
System\Xml\XPath\XPathNavigator.cs (1)
191public override DateTime ValueAsDateTime {
System.Xml.Linq (25)
System\Xml\Linq\XLinq.cs (25)
2937internal static string GetDateTimeString(DateTime value) { 3009else if (value is DateTime) { 3010s = GetDateTimeString((DateTime)value); 4778/// Cast the value of this <see cref="XElement"/> to a <see cref="DateTime"/>. 4781/// The <see cref="XElement"/> to cast to <see cref="DateTime"/>. 4784/// The content of this <see cref="XElement"/> as a <see cref="DateTime"/>. 4787/// Thrown if the specified element does not contain a valid <see cref="DateTime"/> value. 4794public static explicit operator DateTime(XElement element) { 4796return DateTime.Parse(element.Value, CultureInfo.InvariantCulture, System.Globalization.DateTimeStyles.RoundtripKind); 4800/// Cast the value of this <see cref="XElement"/> to an <see cref="DateTime"/>?. 4803/// The <see cref="XElement"/> to cast to <see cref="DateTime"/>?. 4806/// The content of this <see cref="XElement"/> as a <see cref="DateTime"/>?. 4809/// Thrown if the specified element does not contain a valid <see cref="DateTime"/> value. 4813public static explicit operator DateTime?(XElement element) { 4815return DateTime.Parse(element.Value, CultureInfo.InvariantCulture, System.Globalization.DateTimeStyles.RoundtripKind); 6997/// Cast the value of this <see cref="XAttribute"/> to a <see cref="DateTime"/>. 7000/// The <see cref="XAttribute"/> to cast to <see cref="DateTime"/>. 7003/// The content of this <see cref="XAttribute"/> as a <see cref="DateTime"/>. 7009public static explicit operator DateTime(XAttribute attribute) { 7011return DateTime.Parse(attribute.value, CultureInfo.InvariantCulture, System.Globalization.DateTimeStyles.RoundtripKind); 7015/// Cast the value of this <see cref="XAttribute"/> to a <see cref="DateTime"/>?. 7018/// The <see cref="XAttribute"/> to cast to <see cref="DateTime"/>?. Can be null. 7021/// The content of this <see cref="XAttribute"/> as a <see cref="DateTime"/>?. 7024public static explicit operator DateTime?(XAttribute attribute) { 7026return DateTime.Parse(attribute.value, CultureInfo.InvariantCulture, System.Globalization.DateTimeStyles.RoundtripKind);
UIAutomationClient (10)
System\Windows\Automation\RangeValuePattern.cs (10)
275else if (propValue is DateTime) 277return (double)((DateTime)propValue).Year; 324else if (propValue is DateTime) 326return (double)((DateTime)propValue).Year; 358else if (propValue is DateTime) 360return (double)((DateTime)propValue).Year; 396else if (propValue is DateTime) 398return (double)((DateTime)propValue).Year; 433else if (propValue is DateTime) 435return (double)((DateTime)propValue).Year;
WindowsBase (126)
Base\MS\Internal\IO\Packaging\PartBasedPackageProperties.cs (9)
254public override Nullable<DateTime> Created 269public override Nullable<DateTime> Modified 302public override Nullable<DateTime> LastPrinted 426private Nullable<DateTime> GetDateTimePropertyValue(PackageXmlEnum propertyName) 432return (Nullable<DateTime>) valueObject; 736private Nullable<DateTime> GetDateData(XmlTextReader reader) 739DateTime dateTime; 880if (entry.Value is Nullable<DateTime>) 897_xmlWriter.WriteString(XmlConvert.ToString(((Nullable<DateTime>)entry.Value).Value.ToUniversalTime(), "yyyy-MM-ddTHH:mm:ss.fffffffZ"));
Base\MS\Internal\IO\Packaging\StorageBasedPackageProperties.cs (10)
240public override Nullable<DateTime> LastPrinted 256public override Nullable<DateTime> Created 272public override Nullable<DateTime> Modified 598obj = new Nullable<DateTime>(DateTime.FromFileTime(vals[0].union.hVal)); 751else if (propVal is DateTime) 755vals[0].union.hVal = ((DateTime)propVal).ToFileTime(); 793private Nullable<DateTime> 800return obj != null ? (Nullable<DateTime>)obj : new Nullable<DateTime>();
Base\MS\Internal\IO\Packaging\XmlDigitalSignatureProcessor.cs (3)
416internal DateTime SigningTime 1180xDoc.DocumentElement.AppendChild(XmlSignatureProperties.AssembleSignatureProperties(xDoc, DateTime.Now, _manager.TimeFormat, signatureId)); 1303private DateTime _signingTime; // cached value
Base\MS\Internal\IO\Packaging\XmlSignatureProperties.cs (8)
99DateTime dateTime, 156internal static DateTime ParseSigningTime(XmlReader reader, string signatureId, out String timeFormat) 170DateTime signingTime = DateTime.Now; 241private static DateTime ParseSignatureTimeTag(XmlReader reader, out String timeFormat) 355private static String DateTimeToXmlFormattedTime(DateTime dt, string format) 369private static DateTime XmlFormattedTimeToDateTime(String s, String format) 377return DateTime.ParseExact(s, legalFormats, formatter,
Base\MS\Internal\IO\Zip\ZipFileInfo.cs (1)
91internal DateTime LastModFileDateTime
Base\MS\Internal\IO\Zip\ZipIOBlockManager.cs (2)
492internal static UInt32 ToMsDosDateTime(DateTime dateTime) 509internal static DateTime FromMsDosDateTime(UInt32 dosDateTime)
Base\MS\Internal\IO\Zip\ZipIOLocalFileBlock.cs (1)
272_localFileHeader.LastModFileDateTime = ZipIOBlockManager.ToMsDosDateTime(DateTime.Now);
Base\MS\Internal\IO\Zip\ZipIOLocalFileHeader.cs (1)
84header._lastModFileDateTime = ZipIOBlockManager.ToMsDosDateTime(DateTime.Now);
Base\MS\Internal\Security\RightsManagement\ClientSession.cs (17)
440DateTime currentTimeStamp = ExtractIssuedTimeFromCertificateChain(currentCert, DateTime.MinValue); 454DateTime newTimeStamp = ExtractIssuedTimeFromCertificateChain(newCert, DateTime.MinValue); 456if (DateTime.Compare(currentTimeStamp, newTimeStamp) < 0) 1211static private DateTime GetUnboundLicenseDateTimeAttribute( 1215DateTime defaultValue) 1290private static DateTime ExtractIssuedTimeFromCertificateChain( 1292DateTime defaultValue) 1299private static DateTime ExtractIssuedTimeFromCertificate( 1301DateTime defaultValue) 1708DateTime timeFrom = DateTime.MinValue; 1709DateTime timeUntil = DateTime.MaxValue; 1746DateTime.MinValue); 1752DateTime.MaxValue);
Base\MS\Internal\Security\RightsManagement\IssuanceLicense.cs (31)
43DateTime validFrom, 44DateTime validUntil, 77DateTime validFrom, 78DateTime validUntil, 114if ((validFrom != DateTime.MinValue) || (validUntil != DateTime.MaxValue)) 118validFromSysTime = new SystemTime((DateTime)validFrom); 119validUntilSysTime = new SystemTime((DateTime)validUntil); 252DateTime timeFrom; 253DateTime timeUntil; 305DateTime validFrom; 306DateTime validUntil; 467if ((grant.ValidFrom != DateTime.MinValue) || (grant.ValidUntil != DateTime.MaxValue)) 525out DateTime validFrom, 526out DateTime validUntil) 539SystemTime validFromSysTime = new SystemTime(DateTime.Now); 540SystemTime validUntilSysTime = new SystemTime(DateTime.Now); 549validFrom = validFromSysTime.GetDateTime(DateTime.MinValue); 550validUntil = validUntilSysTime.GetDateTime(DateTime.MaxValue); 794out DateTime validFrom, 795out DateTime validUntil) 805validFrom = DateTime.MinValue; 806validUntil = DateTime.MaxValue; 824out DateTime timeFrom, 825out DateTime timeUntil, 875SystemTime timeFromTemp = new SystemTime(DateTime.Now); 876SystemTime timeUntilTemp = new SystemTime(DateTime.Now); 891timeFrom = timeFromTemp.GetDateTime(DateTime.MinValue); 892timeUntil = timeUntilTemp.GetDateTime(DateTime.MaxValue); 956SystemTime frequency = new SystemTime(DateTime.Now);
Base\MS\Internal\Security\RightsManagement\NativeRightsManagementAPIsStructures.cs (3)
58internal SystemTime (DateTime dateTime) 91internal DateTime GetDateTime (DateTime defaultValue)
Base\MS\Internal\Security\RightsManagement\RightNameExpirationInfoPair.cs (6)
31internal RightNameExpirationInfoPair (string rightName, DateTime validFrom, DateTime validUntil) 56internal DateTime ValidFrom 67internal DateTime ValidUntil 76private DateTime _validFrom; 77private DateTime _validUntil;
Base\System\IO\Packaging\CompoundFile\DataSpaceManager.cs (2)
722Int64 timeSeed = DateTime.Now.ToFileTime(); 994Int64 timeSeed = DateTime.Now.ToFileTime();
Base\System\IO\Packaging\CompoundFile\StorageInfo.cs (2)
1187DateTime ConvertFILETIMEToDateTime( System.Runtime.InteropServices.ComTypes.FILETIME time ) 1207return DateTime.FromFileTime(
Base\System\IO\Packaging\PackageDigitalSignature.cs (1)
150public DateTime SigningTime
Base\System\IO\Packaging\PackageDigitalSignatureManager.cs (1)
903collection = collection.Find(X509FindType.FindByTimeValid, DateTime.Now, true);
Base\System\IO\Packaging\PackageProperties.cs (3)
142public abstract Nullable<DateTime> LastPrinted 150public abstract Nullable<DateTime> Created 158public abstract Nullable<DateTime> Modified
Base\System\Security\RightsManagement\Grant.cs (8)
47: this(user, right, DateTime.MinValue, DateTime.MaxValue) 55public ContentGrant(ContentUser user, ContentRight right, DateTime validFrom, DateTime validUntil) 123public DateTime ValidFrom 136public DateTime ValidUntil 148private DateTime _validFrom; 149private DateTime _validUntil;
Base\System\Security\RightsManagement\UnsignedPublishLicense.cs (8)
78DateTime.MinValue, // validFrom, - default 79DateTime.MaxValue, // validUntil, - default 124DateTime.MinValue, // validFrom, - default 125DateTime.MaxValue, // validUntil, - default 271DateTime.MinValue, 272DateTime.MaxValue, 300DateTime.MinValue, // validFrom, - default 301DateTime.MaxValue, // validUntil, - default
Base\System\Windows\Markup\DateTimeConverter2.cs (1)
63if (destinationType != null && value is DateTime)
Base\System\Windows\Markup\TypeConverterHelper.cs (3)
249else if (typeof(DateTime).IsAssignableFrom(type)) 340else if (type == typeof(DateTime)) 440else if (typeof(DateTime).IsAssignableFrom(type))
Base\System\Windows\SplashScreen.cs (4)
46private DateTime _fadeoutEnd; 316_fadeoutEnd = DateTime.UtcNow + _fadeoutDuration; 332DateTime dtNow = DateTime.UtcNow;
Base\System\Windows\Threading\Dispatcher.cs (1)
2780"{0:O} {1} failed", DateTime.Now, methodName));
WsatUI (2)
Configuration\ETWWsatTraceSession.cs (2)
199DateTime localtime = DateTime.Now;
XamlBuildTask (5)
Microsoft\Build\Tasks\Xaml\PartialClassGenerationTask.cs (5)
132private static Dictionary<string, DateTime> referencesTimeStampCache; 306DateTime timeStamp = File.GetLastWriteTimeUtc(fullPath); 309|| timeStamp == DateTime.MinValue) 323referencesTimeStampCache = new Dictionary<string, DateTime>(); 327DateTime timeStamp = File.GetLastWriteTimeUtc(fullPath);