Skip to main content

TimeSpanRange Members

The time span range.

Constructors

Name Description
TimeSpanRange(TimeSpan, TimeSpan) Initializes a new instance of the TimeSpanRange class with specified settings.

Properties

Name Description
Day static Gets the range that specifies the entire day.
Duration Gets the range duration.
End Gets the end value of the range.
IsDay Gets whether the range specifies the entire day.
IsValid Gets whether the end value is greater than or equal to the start value.
IsZero Gets whether Start and End properties are equal to TimeSpan.Zero.
Start Gets the start value of the range.
Zero static

Methods

Name Description
Contains(TimeSpanRange) Checks whether the range contains the specified date-time value.
Contains(TimeSpan, Boolean) Checks whether the range contains the specified time range value.
Equals(TimeSpanRange) Checks whether the specified range is equal to the current range.
Equals(Object, Object) static Determines whether the specified object instances are considered equal. Inherited from Object.
Equals(Object) Checks whether the specified object is equal to the current range.
GetHashCode() Serves as the default hash function.
GetType() Gets the Type of the current instance. Inherited from Object.
Intersect(TimeSpanRange, TimeSpanRange, Boolean) static Computes the intersection of the specified ranges.
Intersect(TimeSpanRange, Boolean) Computes the intersection of the current range with the specified range.
IntersectsWith(TimeSpanRange, TimeSpanRange, Boolean) static Checks whether the time range intersects with the two specified ranges.
IntersectsWith(TimeSpanRange, Boolean) Checks whether the time range intersects with the specified range.
Parse(String, CultureInfo) static Parses the specified string and converts it into the time span range.
ReferenceEquals(Object, Object) static Determines whether the specified Object instances are the same instance. Inherited from Object.
ToString() Returns a string that represents the range.
ToString(IFormatProvider) Returns a string that represents the range, formatted with the specified culture-specific formatting information.
ToString(String, IFormatProvider)
TryParse(String, CultureInfo, out TimeSpanRange) static Tries to parse the specified string and convert it into the time span range.
Union(TimeSpanRange, TimeSpanRange) static Computes the union of the current range with the specified range.
Union(TimeSpanRange) Computes the union of the current range with the specified range.

Operators

Name Description
Equality(TimeSpanRange, TimeSpanRange) static Determines whether two specified ranges have the same value.
Inequality(TimeSpanRange, TimeSpanRange) static Determines whether two specified ranges have different values.
See Also