import java.rmi.*; // rmi bounded buffer producer client process (as opposed to thread) public class bbproducer { public static void main(String[] args) { rmibb buf; int x = 0; // value to be produced try { buf = (rmibb) Naming.lookup("rmi://"+args[1]+"/"+args[0]); while (true) buf.produce(x++); } catch (Exception ee) {ee.printStackTrace();} } //main } // bbproducer