Reuse 1
This commit is contained in:
parent
21ae722975
commit
89867ad20b
@ -8,6 +8,8 @@ import java.nio.file.Paths;
|
||||
import java.util.List;
|
||||
import java.util.Random;
|
||||
|
||||
import fr.ntr.Reuse.Reuse1;
|
||||
import fr.ntr.Reuse.Reuse3;
|
||||
import fr.ntr.scheduler.Scheduler;
|
||||
|
||||
public class AccessPoint {
|
||||
@ -43,8 +45,11 @@ public class AccessPoint {
|
||||
// Simulation
|
||||
cell1.reset();
|
||||
cell2.reset();
|
||||
cell1.updateBandwidth(ticks);
|
||||
cell2.updateBandwidth(ticks);
|
||||
List<Cell> cellList = null;
|
||||
cellList.add(cell1);
|
||||
cellList.add(cell2);
|
||||
Reuse1.BandwithReuse1(cellList,ticks);
|
||||
//Reuse3.BandwithReuse3(cellList,ticks);
|
||||
cell1.schedule();
|
||||
cell2.schedule();
|
||||
|
||||
|
@ -17,13 +17,15 @@ public class ResourceBlock {
|
||||
this.user = user;
|
||||
}
|
||||
|
||||
public User getUser() {
|
||||
return user;
|
||||
}
|
||||
|
||||
public void setBandwidth(double bandwidth) {
|
||||
this.bandwidth = bandwidth;
|
||||
}
|
||||
|
||||
public User getUser() {
|
||||
return user;
|
||||
}
|
||||
|
||||
|
||||
public double getBandwidth() {
|
||||
return bandwidth;
|
||||
|
@ -1,5 +1,15 @@
|
||||
package fr.ntr.Reuse;
|
||||
|
||||
import fr.ntr.Cell;
|
||||
import fr.ntr.User;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class Reuse1 {
|
||||
//TODO Reuse1
|
||||
|
||||
public static void BandwithReuse1(List<Cell> cellList, int tick) {
|
||||
for (Cell cell : cellList) {
|
||||
cell.updateBandwidth(tick);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user