CalendarPlan constructor

const CalendarPlan({
  1. required String name,
  2. @JsonKey(name: 'planid') required int id,
  3. @JsonKey(name: 'enableek') @BoolConverter() required bool optionalTasksEnabled,
  4. required List<PlanDeadline> deadlines,
  5. required List<PlanMember> members,
})

A plan of when to to which MoodleTasks.

Implementation

const factory CalendarPlan({
  /// The name of this plan.
  required String name,

  /// The ID of this plan.
  @JsonKey(name: 'planid') required int id,

  /// `true` if [MoodleTask]s of type [MoodleTaskType.optional] are enabled.
  @JsonKey(name: 'enableek') @BoolConverter() required bool optionalTasksEnabled,

  /// A list of deadlines planned by it's [members].
  required List<PlanDeadline> deadlines,

  /// A list of all [User]s participating in this plan and their respective access type.
  required List<PlanMember> members,
}) = _CalendarPlan;