NotableDateDurationDefinition Class
Definition
- Namespace
- Bodu.Globalization.Calendar
- Assembly
- Bodu.Globalization.Calendar.dll
- Package
- Bodu.Globalization.Calendar 1.0.1
Represents how long a resolved notable-date occurrence lasts: either a fixed number of calendar days or a span whose end date is independently calculated.
public abstract record NotableDateDurationDefinition : IEquatable<NotableDateDurationDefinition>
- Inheritance
-
NotableDateDurationDefinition
- Implements
- Derived
- Inherited Members
- Extension Methods
Remarks
A rule declares at most one duration definition. A null duration means the rule inherits the parent concept's DefaultDurationDays. The two concrete kinds - FixedDurationDefinition and CalculatedEndDateDurationDefinition - are mutually exclusive by construction, so a rule can never declare both a fixed day count and a calculated end date.
Constructors
NotableDateDurationDefinition()
protected NotableDateDurationDefinition()
NotableDateDurationDefinition(NotableDateDurationDefinition)
protected NotableDateDurationDefinition(NotableDateDurationDefinition original)
Parameters
originalNotableDateDurationDefinition
Properties
EqualityContract
protected virtual Type EqualityContract { get; }
Property Value
Methods
Equals(NotableDateDurationDefinition?)
Indicates whether the current object is equal to another object of the same type.
public virtual bool Equals(NotableDateDurationDefinition? other)
Parameters
otherNotableDateDurationDefinitionAn object to compare with this object.
Returns
Equals(object?)
Determines whether the specified object is equal to the current object.
public override bool Equals(object? obj)
Parameters
objobjectThe object to compare with the current object.
Returns
GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
Returns
- int
A hash code for the current object.
PrintMembers(StringBuilder)
protected virtual bool PrintMembers(StringBuilder builder)
Parameters
builderStringBuilder
Returns
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.
Operators
operator ==(NotableDateDurationDefinition?, NotableDateDurationDefinition?)
public static bool operator ==(NotableDateDurationDefinition? left, NotableDateDurationDefinition? right)
Parameters
Returns
operator !=(NotableDateDurationDefinition?, NotableDateDurationDefinition?)
public static bool operator !=(NotableDateDurationDefinition? left, NotableDateDurationDefinition? right)
Parameters
Returns
Applies to
| Product | Versions |
|---|---|
| .NET | 8, 10 |