Weekly class
Represents a schedule that occurs every n weeks on the given weekdays.
Throws an ArgumentError if:
Constructors
-
Weekly({required DateTime startDate, required int frequency, required List<
int> weekdays, DateTime? endDate}) -
Creates a weekly schedule that occurs every
frequencyweeks on the givenweekdays.factory -
Weekly.timed({required DateTime startDate, required int frequency, required List<
int> weekdays, required Iterable<TimeOfDay> timesOfDay, DateTime? endDate}) -
Creates a weekly schedule that occurs every
frequencyweeks on the givenweekdaysat the giventimesOfDay.factory
Properties
- endDate → DateTime?
-
The date that this schedule ends on.
finalinherited
- frequency → int
-
The frequency at which this schedule occurs.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- isTimed → bool
-
Whether this schedule is timed.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- startDate → DateTime
-
The date that this schedule begins on.
finalinherited
- timingMode → ScheduleTimingMode
-
The timing mode of this schedule.
finalinherited
-
weekdays
→ List<
int> -
The weekdays that this schedule occurs on.
final
Methods
-
findNextNOccurrences(
int n, {DateTime? fromDate, List< DateTime> excludeDates = const []}) → List<DateTime> -
Returns a list of the next
ndates for this schedule.inherited -
findNextTillDateOccurrences(
DateTime tillDate, {DateTime? fromDate, List< DateTime> excludeDates = const []}) → List<DateTime> -
Returns a list of dates active on the current schedule through
tillDate.inherited -
getNextNOccurrences(
int n, {DateTime? from, Iterable< DateTime> ? exclude}) → Iterable<DateTime> -
Returns an iterable of the next
noccurrences for this schedule.override -
getOccurrencesUntil(
DateTime end, {DateTime? from, Iterable< DateTime> ? exclude}) → Iterable<DateTime> -
Returns an iterable of the occurrences for this schedule until the given
enddate.override -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
occursAt(
TimeOfDay timeOfDay) → bool -
Determine if this schedule occurs at the given
timeOfDay.inherited -
occursOn(
DateTime date) → bool -
Determine if this schedule includes the given
date.override -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited