This commit is contained in:
manzerbredes 2016-03-22 10:49:04 +01:00
parent 7f3a91e6dc
commit bd27005ead
2 changed files with 50 additions and 42 deletions

View file

@ -19,13 +19,14 @@ import structure.Router;
public class Main {
public static void main(String[] args) {
Grid g=new Grid(Grid.Protocol.CUSTOM);
Grid g=new Grid(Grid.Protocol.AODV);
// Build Graph for graphstream
MyGraph gr=new MyGraph("Routage Oportuniste", g);
gr.display();
// Update Graph
while(true){
try {
Thread.sleep(1000);
@ -33,7 +34,7 @@ public class Main {
// TODO Auto-generated catch block
e.printStackTrace();
}
g.buildRandomLink();
g.buildEdgeWithRandomWeigth();
System.out.println("Update !");
gr.update();
}