test
This commit is contained in:
parent
7f3a91e6dc
commit
bd27005ead
2 changed files with 50 additions and 42 deletions
|
@ -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();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue