DatepickerComparison.reclamp constructor

DatepickerComparison.reclamp(
  1. DatepickerComparison? orig,
  2. Date? min,
  3. Date? max
)

Construct a copy of original clamped to the given min/max dates. Existing clamping is removed before the new clamping is applied.

Implementation

DatepickerComparison.reclamp(DatepickerComparison? orig, Date? min, Date? max)
    : this.custom(orig?.range?.unclamped().clamp(min: min, max: max),
          orig?.comparison?.unclamped().clamp(min: min, max: max));