durationPickerConstraints

fun durationPickerConstraints(minDuration: Duration? = null, maxDuration: Duration? = null): DurationPickerConstraints

Creates inclusive whole-minute scalar constraints for a duration picker.

Return

A DurationPickerConstraints instance with the specified bounds.

Parameters

minDuration

The smallest selectable duration, inclusive. Pass null to omit the lower bound.

maxDuration

The largest selectable duration, inclusive. Pass null to omit the upper bound.

Throws

if a bound is outside the supported duration domain or the lower bound is greater than the upper bound.