diff --git a/src/main/java/fr/ntr/scheduler/MaxSNR.java b/src/main/java/fr/ntr/scheduler/MaxSNR.java index c346bfd..0fc7211 100644 --- a/src/main/java/fr/ntr/scheduler/MaxSNR.java +++ b/src/main/java/fr/ntr/scheduler/MaxSNR.java @@ -1,18 +1,28 @@ package fr.ntr.scheduler; import java.util.List; +import fr.ntr.ResourceBlock; import fr.ntr.User; public class MaxSNR extends Scheduler { private List users; + private ResourceBlock[][] frame; + @Override public void scheduling() { User userMax = null; for(int ts = 0; ts < 2; ts++){ for(int sp = 0; sp < 100; sp++){ userMax = selectionUtilisateur(sp, ts, users); + if (userMax.getPacketsToSend() == null) { + users.remove(userMax); + }else{ + //sub the packet send need Set packet + userMax.getPacketsToSend(); + } + frame[ts][sp].setUser(selectionUtilisateur(sp, ts, users)); } } }