DatepickerDateRange constructor

DatepickerDateRange({
  1. DateRange? dateRange,
  2. int? daysAgo,
  3. int? weeksAgo,
  4. int? monthsAgo,
  5. int? yearsAgo,
  6. int? lastNDays,
  7. bool? allTimeRange,
  8. int? broadcastMonthsAgo,
  9. int? lastNDaysToToday,
  10. int? quartersAgo,
  11. int? startWeekday,
  12. int? nextNDaysFromToday,
})

Implementation

factory DatepickerDateRange({
  DateRange? dateRange,
  $core.int? daysAgo,
  $core.int? weeksAgo,
  $core.int? monthsAgo,
  $core.int? yearsAgo,
  $core.int? lastNDays,
  $core.bool? allTimeRange,
  $core.int? broadcastMonthsAgo,
  $core.int? lastNDaysToToday,
  $core.int? quartersAgo,
  $core.int? startWeekday,
  $core.int? nextNDaysFromToday,
}) {
  final _result = create();
  if (dateRange != null) {
    _result.dateRange = dateRange;
  }
  if (daysAgo != null) {
    _result.daysAgo = daysAgo;
  }
  if (weeksAgo != null) {
    _result.weeksAgo = weeksAgo;
  }
  if (monthsAgo != null) {
    _result.monthsAgo = monthsAgo;
  }
  if (yearsAgo != null) {
    _result.yearsAgo = yearsAgo;
  }
  if (lastNDays != null) {
    _result.lastNDays = lastNDays;
  }
  if (allTimeRange != null) {
    _result.allTimeRange = allTimeRange;
  }
  if (broadcastMonthsAgo != null) {
    _result.broadcastMonthsAgo = broadcastMonthsAgo;
  }
  if (lastNDaysToToday != null) {
    _result.lastNDaysToToday = lastNDaysToToday;
  }
  if (quartersAgo != null) {
    _result.quartersAgo = quartersAgo;
  }
  if (startWeekday != null) {
    _result.startWeekday = startWeekday;
  }
  if (nextNDaysFromToday != null) {
    _result.nextNDaysFromToday = nextNDaysFromToday;
  }
  return _result;
}