The TimeOfDay type exposes the following members.

Constructors

  NameDescription
Public methodTimeOfDay(Int64)
Initializes a new instance of the TimeOfDay structure to the specified number of ticks.
Public methodTimeOfDay(TimeSpan)
Initializes a new instance of the TimeOfDay structure.
Public methodTimeOfDay(Int32, Int32, Int32)
Initializes a new instance of the TimeOfDay structure to a specified number of hours, minutes, and seconds.
Public methodTimeOfDay(Int32, Int32, Int32, Int32)
Initializes a new instance of the TimeOfDay structure to a specified number of days, hours, minutes, and seconds.
Public methodTimeOfDay(Int32, Int32, Int32, Int32, Int32)
Initializes a new instance of the TimeOfDay structure to a specified number of days, hours, minutes, seconds, and milliseconds.

Methods

  NameDescription
Public methodAdd
Adds the value of the specified TimeSpan to the value of this instance.
Public methodStatic memberCompare
Compares two instances of TimeOfDay and returns an indication of their relative values.
Public methodCompareTo(Object)
Compares the value of this instance to a specified object that contains a specified TimeOfDay or TimeSpan value, and returns an integer that indicates whether this instance is earlier than, the same as, or later than the specified TimeOfDay or TimeSpan value.
Public methodCompareTo(TimeOfDay)
Compares the value of this instance to a specified TimeOfDay value and returns an integer that indicates whether this instance is earlier than, the same as, or later than the specified TimeOfDay value.
Public methodEquals(Object)
Returns a value that indicates whether this instance is equal to a specified object.
(Overrides ValueType..::..Equals(Object).)
Public methodEquals(TimeOfDay)
Returns a value that indicates whether this instance is equal to the specified TimeOfDay instance.
Public methodStatic memberEquals(TimeOfDay, TimeOfDay)
Returns a value that indicates whether two instances of TimeOfDay are equal.
Protected methodFinalize (Inherited from Object.)
Public methodStatic memberFromDays
Returns a TimeOfDay that represents a specified number of days, where the specification is accurate to the nearest millisecond.
Public methodStatic memberFromHours
Returns a TimeOfDay that represents a specified number of hours, where the specification is accurate to the nearest millisecond.
Public methodStatic memberFromMilliseconds
Returns a TimeOfDay that represents a specified number of milliseconds.
Public methodStatic memberFromMinutes
Returns a TimeOfDay that represents a specified number of minutes, where the specification is accurate to the nearest millisecond.
Public methodStatic memberFromSeconds
Returns a TimeOfDay that represents a specified number of seconds, where the specification is accurate to the nearest millisecond.
Public methodStatic memberFromTicks
Returns a TimeOfDay that represents a specified time, where the specification is in units of ticks.
Public methodGetHashCode
Returns the hash code for this instance.
(Overrides ValueType..::..GetHashCode()()()().)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodNegate
Returns the negated TimeSpan of this instance.
Public methodStatic memberParse
Converts the specified string representation of a time of day to its TimeOfDay equivalent.
Public methodSubtract
Subtracts the specified TimeSpan from this instance.
Public methodToString
Converts the value of the current TimeOfDay object to its equivalent string representation.
(Overrides ValueType..::..ToString()()()().)
Public methodToTimeSpan
Returns a time span value based on the current time of day value.
Public methodStatic memberTryParse
Converts the specified string representation of a time of day to its TimeOfDay equivalent.

Operators

  NameDescription
Public operatorStatic memberAddition
Adds a specified time interval to a specified time of day, yielding a new time span.
Public operatorStatic memberEquality
Determines whether a specified instance of TimeOfDay is equal to a specified TimeSpan.
Public operatorStatic memberGreaterThan
Determines whether one specified TimeOfDay is greater than a specified TimeSpan.
Public operatorStatic memberGreaterThanOrEqual
Determines whether one specified TimeOfDay is greater than or equal to a specified TimeSpan.
Public operatorStatic memberImplicitWideningImplicitImplicitImplicit(TimeSpan to TimeOfDay)
Casts a time span value to a time of day value.
Public operatorStatic memberImplicitWideningImplicitImplicitImplicit(TimeOfDay to TimeSpan)
Casts a time of day value to a time span value.
Public operatorStatic memberInequality
Determines whether a specified instance of TimeOfDay is not equal to a specified TimeSpan.
Public operatorStatic memberLessThan
Determines whether one specified TimeOfDay is less than a specified TimeSpan.
Public operatorStatic memberLessThanOrEqual
Determines whether one specified TimeOfDay is less than or equal to a specified TimeSpan.
Public operatorStatic memberSubtraction
Subtracts a specified time interval from a specified time of day, yielding a new time span.
Public operatorStatic memberUnaryNegation
Returns the negated time span of the specified time of day.
Public operatorStatic memberUnaryPlus
Returns the time span of the specified time of day.

Fields

  NameDescription
Public fieldStatic memberMaxValue
Represents the largest possible value of TimeOfDay. This field is read-only.
Public fieldStatic memberMinValue
Represents the smallest possible value of TimeOfDay. This field is read-only.

Properties

  NameDescription
Public propertyDays
Gets the days component of the time interval represented by the current TimeOfDay structure.
Public propertyHours
Gets the hours component of the time interval represented by the current TimeOfDay structure.
Public propertyMilliseconds
Gets the milliseconds component of the time interval represented by the current TimeOfDay structure.
Public propertyMinutes
Gets the minutes component of the time interval represented by the current TimeOfDay structure.
Public propertySeconds
Gets the seconds component of the time interval represented by the current TimeOfDay structure.
Public propertyTicks
Gets the number of ticks that represent the value of the current TimeOfDay structure.
Public propertyTotalDays
Gets the value of the current TimeOfDay structure expressed in whole and fractional days.
Public propertyTotalHours
Gets the value of the current TimeOfDay structure expressed in whole and fractional hours.
Public propertyTotalMilliseconds
Gets the value of the current TimeOfDay structure expressed in whole and fractional milliseconds.
Public propertyTotalMinutes
Gets the value of the current TimeOfDay structure expressed in whole and fractional minutes.
Public propertyTotalSeconds
Gets the value of the current TimeOfDay structure expressed in whole and fractional seconds.

See Also