Up Previous Next

Everything stays the same, and works just fine, except Setupo.java needs to be updated:

import java.rmi.*; 

class Setup {
  public static void main(String[] args) throws RemoteException{

    Server server = new Server(); 

    int cols = 10, rows = 10;

    Client a = new Client(cols, rows); 
    a.registerWith(server); 

    Client b = new Client(cols, rows); 
    b.registerWith(server); 

    Client c = new Client(cols, rows); 
    c.registerWith(server); 

  } 
}
Now we can run any of the three possible setups, things would work just as well.


Up Previous Next