How do I Browse and Dynamically Invoke Remote Objects?

By Cliff Berg

Dr. Dobb's Journal December 1997

Class c = RMIClassLoader.loadClass(new URL("http://somehost/somedir/"), "somepackage.MyMainClass");
Runnable myObject = c.newInstance();  // the class must have 
                                      //   an empty constructor
                    c.run();          // this can do anything. 
                                      //   it implements your application

Example 1: The RMI class loader.

Back to Article


Copyright © 1997, Dr. Dobb's Journal