C# 클래스 EGSW.Services.Directory.DateTimeHelper

Represents a datetime helper
상속: IDateTimeHelper
파일 보기 프로젝트 열기: careerengine/EGSW-Project

공개 메소드들

메소드 설명
ConvertToUserTime ( System.DateTime dt ) : System.DateTime

Converts the date and time to current user date and time

ConvertToUserTime ( System.DateTime dt, DateTimeKind sourceDateTimeKind ) : System.DateTime

Converts the date and time to current user date and time

ConvertToUserTime ( System.DateTime dt, TimeZoneInfo sourceTimeZone ) : System.DateTime

Converts the date and time to current user date and time

ConvertToUserTime ( System.DateTime dt, TimeZoneInfo sourceTimeZone, TimeZoneInfo destinationTimeZone ) : System.DateTime

Converts the date and time to current user date and time

ConvertToUtcTime ( System.DateTime dt ) : System.DateTime

Converts the date and time to Coordinated Universal Time (UTC)

ConvertToUtcTime ( System.DateTime dt, DateTimeKind sourceDateTimeKind ) : System.DateTime

Converts the date and time to Coordinated Universal Time (UTC)

ConvertToUtcTime ( System.DateTime dt, TimeZoneInfo sourceTimeZone ) : System.DateTime

Converts the date and time to Coordinated Universal Time (UTC)

DateTimeHelper ( IWorkContext workContext ) : System

Ctor

FindTimeZoneById ( string id ) : TimeZoneInfo

Retrieves a System.TimeZoneInfo object from the registry based on its identifier.

GetCustomerTimeZone ( Customer customer ) : TimeZoneInfo

Gets a customer time zone

GetSystemTimeZones ( ) : ReadOnlyCollection

Returns a sorted collection of all the time zones

메소드 상세

ConvertToUserTime() 공개 메소드

Converts the date and time to current user date and time
public ConvertToUserTime ( System.DateTime dt ) : System.DateTime
dt System.DateTime The date and time (respesents local system time or UTC time) to convert.
리턴 System.DateTime

ConvertToUserTime() 공개 메소드

Converts the date and time to current user date and time
public ConvertToUserTime ( System.DateTime dt, DateTimeKind sourceDateTimeKind ) : System.DateTime
dt System.DateTime The date and time (respesents local system time or UTC time) to convert.
sourceDateTimeKind DateTimeKind The source datetimekind
리턴 System.DateTime

ConvertToUserTime() 공개 메소드

Converts the date and time to current user date and time
public ConvertToUserTime ( System.DateTime dt, TimeZoneInfo sourceTimeZone ) : System.DateTime
dt System.DateTime The date and time to convert.
sourceTimeZone System.TimeZoneInfo The time zone of dateTime.
리턴 System.DateTime

ConvertToUserTime() 공개 메소드

Converts the date and time to current user date and time
public ConvertToUserTime ( System.DateTime dt, TimeZoneInfo sourceTimeZone, TimeZoneInfo destinationTimeZone ) : System.DateTime
dt System.DateTime The date and time to convert.
sourceTimeZone System.TimeZoneInfo The time zone of dateTime.
destinationTimeZone System.TimeZoneInfo The time zone to convert dateTime to.
리턴 System.DateTime

ConvertToUtcTime() 공개 메소드

Converts the date and time to Coordinated Universal Time (UTC)
public ConvertToUtcTime ( System.DateTime dt ) : System.DateTime
dt System.DateTime The date and time (respesents local system time or UTC time) to convert.
리턴 System.DateTime

ConvertToUtcTime() 공개 메소드

Converts the date and time to Coordinated Universal Time (UTC)
public ConvertToUtcTime ( System.DateTime dt, DateTimeKind sourceDateTimeKind ) : System.DateTime
dt System.DateTime The date and time (respesents local system time or UTC time) to convert.
sourceDateTimeKind DateTimeKind The source datetimekind
리턴 System.DateTime

ConvertToUtcTime() 공개 메소드

Converts the date and time to Coordinated Universal Time (UTC)
public ConvertToUtcTime ( System.DateTime dt, TimeZoneInfo sourceTimeZone ) : System.DateTime
dt System.DateTime The date and time to convert.
sourceTimeZone System.TimeZoneInfo The time zone of dateTime.
리턴 System.DateTime

DateTimeHelper() 공개 메소드

Ctor
public DateTimeHelper ( IWorkContext workContext ) : System
workContext IWorkContext Work context
리턴 System

FindTimeZoneById() 공개 메소드

Retrieves a System.TimeZoneInfo object from the registry based on its identifier.
public FindTimeZoneById ( string id ) : TimeZoneInfo
id string The time zone identifier, which corresponds to the System.TimeZoneInfo.Id property.
리턴 System.TimeZoneInfo

GetCustomerTimeZone() 공개 메소드

Gets a customer time zone
public GetCustomerTimeZone ( Customer customer ) : TimeZoneInfo
customer EGSW.Data.Customer Customer
리턴 System.TimeZoneInfo

GetSystemTimeZones() 공개 메소드

Returns a sorted collection of all the time zones
public GetSystemTimeZones ( ) : ReadOnlyCollection
리턴 ReadOnlyCollection