Table of Contents

Class Period

Namespace
Arc4u
Assembly
Arc4u.dll

Represents a period. This class cannot be inherited.

public sealed class Period : Interval<DateTimeOffset?>, IEquatable<Interval<DateTimeOffset?>>, IComparable<Interval<DateTimeOffset?>>, IFormattable
Inheritance
Period
Implements
Inherited Members

Constructors

Period(Bound<DateTimeOffset?>, Bound<DateTimeOffset?>)

Initializes a new instance of the Period class.

[JsonConstructor]
public Period(Bound<DateTimeOffset?> lowerBound, Bound<DateTimeOffset?> upperBound)

Parameters

lowerBound Bound<DateTimeOffset?>

The lower bound.

upperBound Bound<DateTimeOffset?>

The upper bound.

Period(DateTimeOffset?, DateTimeOffset?)

Initializes a new instance of the Period class with an included lowerValue and an excluded upperValue.

public Period(DateTimeOffset? lowerValue, DateTimeOffset? upperValue)

Parameters

lowerValue DateTimeOffset?

The lower value.

upperValue DateTimeOffset?

The upper value.

Period(DateTimeOffset?, DateTimeOffset?, bool)

Initializes a new instance of the Period class with an included lowerValue.

public Period(DateTimeOffset? lowerValue, DateTimeOffset? upperValue, bool upperIncluded)

Parameters

lowerValue DateTimeOffset?

The lower value.

upperValue DateTimeOffset?

The upper value.

upperIncluded bool

true if the upperValue is included in the Period; otherwise, false.

Period(DateTimeOffset?, DateTimeOffset?, bool, bool)

Initializes a new instance of the Period class.

public Period(DateTimeOffset? lowerValue, DateTimeOffset? upperValue, bool lowerIncluded, bool upperIncluded)

Parameters

lowerValue DateTimeOffset?

The lower value.

upperValue DateTimeOffset?

The upper value.

lowerIncluded bool

true if the lowerValue is included in the Period; otherwise, false.

upperIncluded bool

true if the upperValue is included in the Period; otherwise, false.

Methods

ToString(IFormatProvider)

Converts the value of the current Period object to its equivalent string representation using the specified culture-specific format information.

public string ToString(IFormatProvider formatProvider)

Parameters

formatProvider IFormatProvider

An IFormatProvider object that supplies culture-specific formatting information.

Returns

string

A string representation of the value of the current Period object, as specified by formatProvider.

ToString(string)

Converts the value of the current Period object to its equivalent string representation using the specified format information.

public string ToString(string format)

Parameters

format string

A format string.

Returns

string

A string representation of the value of the current Period object, as specified by format.

ToString(string?, IFormatProvider?)

Converts the value of the current Period object to its equivalent string representation using the specified format and culture-specific format information.

public string ToString(string? format, IFormatProvider? formatProvider)

Parameters

format string

A format string.

formatProvider IFormatProvider

An IFormatProvider object that supplies culture-specific formatting information.

Returns

string

A string representation of the value of the current Period object, as specified by format and formatProvider.