DateTimeHelper MembersKentico 8.1 API Reference
The DateTimeHelper type exposes the following members.
Constructors

  NameDescription
Public methodDateTimeHelper
Back to Top
Methods

  NameDescription
Public methodStatic memberDateTimeToString
Converts the given DateTime to string value.
Public methodOnlineEquals
Determines whether the specified OnlineObject is equal to the current OnlineObject.
(Inherited from OnlineObject.)
Protected methodOnlineFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from OnlineObject.)
Public methodStatic memberGetDayStart
Gets start of the day of specific date.
Public methodStatic memberGetFirstDayOfWeek 
Gets the first day of the week.
Public methodStatic memberGetFirstDayOfWeek(String)
Gets the first day of the week.
Public methodStatic memberGetFormattedValidity
Returns validity as formatted string.
Public methodOnlineGetHashCode
Serves as a hash function for a particular type.
(Inherited from OnlineObject.)
Public methodStatic memberGetHourStart
Gets current date without minutes and seconds.
Public methodStatic memberGetMinuteStart
Gets current date without seconds.
Public methodStatic memberGetMonthStart
Gets the first day of the month from specific date.
Public methodOnlineGetType
Gets the OnlineType of the current instance.
(Inherited from OnlineObject.)
Public methodStatic memberGetValidityEnum
Returns validity enumeration.
Public methodStatic memberGetValidityString
Returns validity enumeration as string.
Public methodStatic memberGetValidTo
Calculate valid to date and time according to given parameters.
Public methodStatic memberGetWeekOfYear(DateTime)
Gets the week of year number.
Public methodStatic memberGetWeekOfYear(DateTime, String)
Gets the week of year number.
Public methodStatic memberGetWeekStart(DateTime)
Gets the date from the beginning of week.
Public methodStatic memberGetWeekStart(DateTime, String)
Gets the date from the beginning of week.
Public methodStatic memberGetYearStart
Gets the first day of the year from specific date.
Public methodStatic memberIsNowOrToday
Returns true, if the given value is ##NOW## or ##TODAY## macro
Public methodStatic memberIsValidFromTo
Returns true if DateTime "from" is lower than or equal to DateTime "to" or one of them is equal to ZeroTime.
Protected methodOnlineMemberwiseClone
Creates a shallow copy of the current OnlineObject.
(Inherited from OnlineObject.)
Public methodStatic memberNumberOfWeeks(DateTime, DateTime)
Gets number of weeks in specified time interval.
Public methodStatic memberNumberOfWeeks(DateTime, DateTime, String)
Gets number of weeks in specified time interval.
Public methodOnlineToString
Returns a string that represents the current object.
(Inherited from OnlineObject.)
Back to Top
Extension Methods

  NameDescription
Public Extension MethodAsValue
Converts object to a query value which can be used as a query parameter
(Defined by QueryExtensions.)
Public Extension MethodGetAPIString
Gets the string by the specified resource key
(Defined by CoreExtensions.)
Public Extension MethodGetString
Gets the string by the specified resource key
(Defined by CoreExtensions.)
Public Extension MethodToBoolean
Returns the boolean representation of an object or default value if not.
(Defined by CoreExtensions.)
Public Extension MethodToDateTime
Returns the DateTime representation of an object or default value if not.
(Defined by CoreExtensions.)
Public Extension MethodToDouble
Returns the double representation of an object or default value if not.
(Defined by CoreExtensions.)
Public Extension MethodToGuid
Returns the Guid representation of an object or default value if not.
(Defined by CoreExtensions.)
Public Extension MethodToInteger
Returns the integer representation of an object or default value if not.
(Defined by CoreExtensions.)
Public Extension MethodToString
Returns the string representation of an object or default value if not.
(Defined by CoreExtensions.)
Back to Top
Fields

  NameDescription
Public fieldStatic memberMACRO_DATE_TODAY
Macro representing current date.
Public fieldStatic memberMACRO_TIME_NOW
Macro representing current date and time.
Public fieldStatic memberUNIX_TIME_START
Start date/time for the Unix time stamp
Public fieldStatic memberZERO_TIME
Zero time constant.
Back to Top
Properties

  NameDescription
Public propertyStatic memberDefaultIFormatProvider
Gets the default (en-us) IFormatProvider.
Back to Top
See Also