//TODO: allow choice of chairs internal CaseBoard GetAllocation( AppealCase appealCase, Member chair, IEnumerable <Member> possibleRapporteurs, IEnumerable <Member> possibleSecondMembers) { Member rapporteur; Member second; rapporteur = _getMemberWithFewestAllocations( possibleRapporteurs .Where(x => x != chair)); second = _getMemberWithFewestAllocations( possibleSecondMembers .Where(x => x != chair && x != rapporteur)); _allocationCount[chair]++; _allocationCount[rapporteur]++; _allocationCount[second]++; return(new CaseBoard( new ChairWorker(chair), new RapporteurWorker(rapporteur), new SecondWorker(second) )); }
internal override void ScheduleOP(Hour currentHour, AppealCase appealCase, CaseBoard workers) { WorkCase opCase = new OPCase(appealCase, workers); opCase.LogEnqueued(currentHour); _opSchedule.Schedule(currentHour, appealCase, workers); }
internal WorkCaseCommon(AppealCase appealCase, CaseBoard workers) { _case = appealCase ?? throw new ArgumentException("appealCase may not be null"); _caseBoard = workers ?? throw new ArgumentException("workers may not be null"); _setupWorkerQueue(workers); _setupWork(); }
internal override void ProcessNewCase(AppealCase appealCase, Hour currentHour) { CaseBoard allocation = _allocator.GetAllocation( appealCase, Chair, Technicals, _getSecondMemberChoices()); WorkCase summonsCase = new SummonsCase(appealCase, allocation); _registrar.ProcessNewSummons(summonsCase); _registrar.CirculateCases(currentHour); }
internal abstract void ProcessNewCase(AppealCase appealCase, Hour currentHour);
public OPCase(AppealCase appealCase, CaseBoard workers) : base(appealCase, workers) { }
public DecisionCase(AppealCase appealCase, CaseBoard workers) : base(appealCase, workers) { }
internal SummonsCase(AppealCase appealCase, CaseBoard workers) : base(appealCase, workers) { }
internal abstract void ScheduleOP(Hour currentHour, AppealCase appealCase, CaseBoard workers);
internal abstract void Schedule(Hour startHour, AppealCase appealCase, CaseBoard caseBoard);