public void displaySJF_N() { int num = myScheduling.getNumberProcess(); for (int i = 0; i < num; i++) { processWaitingTime[i].Text = myScheduling.waitingTime_SJF_N[i].ToString(); processTurnaroundTime[i].Text = myScheduling.turnAroundTime_SJF_N[i].ToString(); } lbl_avg_waitingTime.Text = "" + myScheduling.getAVG_waitingTimeSJF_N().ToString("0.00"); lbl_contextSwitch.Text = "" + myScheduling.getContextSwitch_SJF_N(); }
public void setData() { int num = myScheduling.getNumberProcess(); for (int i = 0; i < num; i++) { label_Aviral[i].Text = myScheduling.getArrivalTime(i).ToString(); label_Burst[i].Text = myScheduling.getBrustTime(i).ToString(); label_Priority[i].Text = myScheduling.getPriority(i).ToString(); } if (myScheduling.getFlagFCFS()) { lbl_avg_FCFS.Text = "" + myScheduling.getAVG_waitingTimeFCFS().ToString("0.00"); lbl_contextSwitch_FCFS.Text = "" + myScheduling.getContextSwitch_FCFS(); } if (myScheduling.getFlagSJF_P()) { lbl_avg_SJF_P.Text = "" + myScheduling.getAVG_waitingTimePriority_P().ToString("0.00"); lbl_contextSwitch_SJF_P.Text = "" + myScheduling.getContextSwitch_SJF_P(); } if (myScheduling.getFlagSJF_N()) { lbl_avg_SJF_N.Text = "" + myScheduling.getAVG_waitingTimeSJF_N().ToString("0.00"); lbl_contextSwitch_SJF_N.Text = "" + myScheduling.getContextSwitch_SJF_N(); } if (myScheduling.getFlagPriority_P()) { lbl_avg_Priority_P.Text = "" + myScheduling.getAVG_waitingTimePriority_P().ToString("0.00"); lbl_contextSwitch_Priority_P.Text = "" + myScheduling.getContextSwitch_Priority_P(); } if (myScheduling.getFlagPriority_N()) { lbl_avg_Priority_N.Text = "" + myScheduling.getAVG_waitingTimePriority_N().ToString("0.00"); lbl_contextSwitch_Priority_N.Text = "" + myScheduling.getContextSwitch_Priority_N(); } if (myScheduling.getFlagRR()) { lbl_avg_RR.Text = "" + myScheduling.getAVG_waitingTimeRR().ToString("0.00"); lbl_contextSwitch_RR.Text = "" + myScheduling.getContextSwitch_RR(); lbl_quantumTime.Text = "" + myScheduling.getQuantumTime().ToString(); } }