public class NullAPController extends java.lang.Object implements APController
Modifier and Type | Method and Description |
---|---|
void |
addAccessPoint(long time,
int gid,
GlobalController g)
Add new access point with ID gid
|
void |
addLink(long time,
int gid1,
int gid2)
Add link to network
|
void |
addNode(long time,
int gid)
Add node to network
|
void |
addWarmUpNode(long time)
Add warm up (not real) node
|
int |
APTrafficEstimate(GlobalController g)
Return an estimate of traffic for all nodes and APs
|
void |
controllerRemove(long time,
GlobalController g)
Use the controller to remove the least efficient AP
|
void |
controllerUpdate(long time,
GlobalController g)
Controller regular AP update action
|
Pair<java.lang.Integer,java.lang.Integer> |
findClosestAP(int gid,
GlobalController g)
Return the gid and cost of the closest AP or null if there is no such AP
|
int |
getAP(int gid)
Return AP for given gid (or 0 if none)
|
int |
getAPCost(int gid)
Return APCost for given gid (or max dist if none)
|
java.util.ArrayList<java.lang.Integer> |
getAPList()
Return list of access points
|
int |
getNoAPs()
Return number of access points
|
int |
getScore(long tim,
int gid,
GlobalController g)
No score for this function
|
boolean |
isAP(int gid)
is node an AP
|
double |
meanAPLife()
Return the mean life of an AP -- this only includes APs which have
died
|
double |
meanAPLifeSoFar(long time)
Return the mean life of an AP -- includes all
|
double |
meanNodeLife()
Return the mean life of a node -- this only includes
nodes which have died
|
APInfo |
newAPInfo()
/** Create new APInfo
|
java.util.ArrayList<java.lang.Integer> |
nonAPNodes(GlobalController g)
Return a list of potential access points
|
void |
removeAccessPoint(long time,
int gid)
Remove access point with ID gid
|
void |
removeLink(long time,
int gid1,
int gid2)
Remove link from network
|
void |
removeNode(long time,
int gid)
Node has been removed from network and hence can no longer be AP --
note that access points will
|
void |
removeWarmUpNode(long startTime,
long endTime)
Remove warm up (not real) node
|
void |
routerUpdate(RouterController r)
Router regular AP update action
|
void |
setAP(int gid,
int ap,
int cost,
GlobalController g)
Set AP for given gid
|
public int getNoAPs()
getNoAPs
in interface APController
public java.util.ArrayList<java.lang.Integer> getAPList()
getAPList
in interface APController
public boolean isAP(int gid)
isAP
in interface APController
public int getAP(int gid)
getAP
in interface APController
public int getAPCost(int gid)
getAPCost
in interface APController
public void setAP(int gid, int ap, int cost, GlobalController g)
public void routerUpdate(RouterController r)
routerUpdate
in interface APController
public void controllerUpdate(long time, GlobalController g)
controllerUpdate
in interface APController
public void controllerRemove(long time, GlobalController g)
controllerRemove
in interface APController
public java.util.ArrayList<java.lang.Integer> nonAPNodes(GlobalController g)
public int APTrafficEstimate(GlobalController g)
APTrafficEstimate
in interface APController
public void addAccessPoint(long time, int gid, GlobalController g)
addAccessPoint
in interface APController
public void removeAccessPoint(long time, int gid)
removeAccessPoint
in interface APController
public Pair<java.lang.Integer,java.lang.Integer> findClosestAP(int gid, GlobalController g)
public void addNode(long time, int gid)
addNode
in interface APController
public void removeNode(long time, int gid)
removeNode
in interface APController
public void addWarmUpNode(long time)
addWarmUpNode
in interface APController
public void removeWarmUpNode(long startTime, long endTime)
removeWarmUpNode
in interface APController
public void addLink(long time, int gid1, int gid2)
addLink
in interface APController
public void removeLink(long time, int gid1, int gid2)
removeLink
in interface APController
public int getScore(long tim, int gid, GlobalController g)
getScore
in interface APController
public double meanNodeLife()
meanNodeLife
in interface APController
public double meanAPLife()
meanAPLife
in interface APController
public double meanAPLifeSoFar(long time)
meanAPLifeSoFar
in interface APController
public APInfo newAPInfo()
newAPInfo
in interface APController
User Space Routing 0.10.3