Method ToLocalDateTime
ToLocalDateTime(DateTimeOffset, ClaimsPrincipal)
Declaration
public static DateTime ToLocalDateTime(this DateTimeOffset dateTimeOffset, ClaimsPrincipal principal)
Parameters
Returns
Type |
Description |
DateTime |
A new DateTime instance that represents the date and time of the current
DateTimeOffset instance converted to the time zone of the principal
with fallback to the local time of the system.
|
ToLocalDateTime(Nullable<DateTimeOffset>, ClaimsPrincipal)
Returns a new
System.Nullable<> instance based on the current
System.Nullable<> instance that represents the local time for a given
ClaimsPrincipal's time zone.
Declaration
public static Nullable<DateTime> ToLocalDateTime(this Nullable<DateTimeOffset> dateTimeOffset, ClaimsPrincipal principal)
Parameters
Returns
Type |
Description |
System.Nullable<DateTime> |
A new System.Nullable<> instance that represents the date and time of the current
System.Nullable<> instance converted to the time zone of the
principal with fallback to the local time of the system.
|