getStart/ 0040775 0074524 0012666 00000000000 06604453543 0014121 5 ustar 00jvolpe jinieast 0000254 0000004 getStart/Hello.java 0100644 0074524 0012666 00000000257 06535610713 0016023 0 ustar 00jvolpe jinieast 0000254 0000004 package examples.hello; import java.rmi.Remote; import java.rmi.RemoteException; public interface Hello extends Remote { String sayHello() throws RemoteException; } getStart/HelloApplet.java 0100644 0074524 0012666 00000001357 06535611156 0017175 0 ustar 00jvolpe jinieast 0000254 0000004 package examples.hello; import java.applet.Applet; import java.awt.Graphics; import java.rmi.Naming; import java.rmi.RemoteException; public class HelloApplet extends Applet { String message = "blank"; // "obj" is the identifier that we'll use to refer // to the remote object that implements the "Hello" // interface Hello obj = null; public void init() { try { obj = (Hello)Naming.lookup("//" + getCodeBase().getHost() + "/HelloServer"); message = obj.sayHello(); } catch (Exception e) { System.out.println("HelloApplet exception: " + e.getMessage()); e.printStackTrace(); } } public void paint(Graphics g) { g.drawString(message, 25, 50); } } getStart/HelloImpl.java 0100644 0074524 0012666 00000001674 06535614005 0016647 0 ustar 00jvolpe jinieast 0000254 0000004 package examples.hello; import java.rmi.Naming; import java.rmi.RemoteException; import java.rmi.RMISecurityManager; import java.rmi.server.UnicastRemoteObject; public class HelloImpl extends UnicastRemoteObject implements Hello { public HelloImpl() throws RemoteException { super(); } public String sayHello() { return "Hello World!"; } public static void main(String args[]) { // Create and install a security manager if (System.getSecurityManager() == null) { System.setSecurityManager(new RMISecurityManager()); } try { HelloImpl obj = new HelloImpl(); // Bind this object instance to the name "HelloServer" Naming.rebind("HelloServer", obj); System.out.println("HelloServer bound in registry"); } catch (Exception e) { System.out.println("HelloImpl err: " + e.getMessage()); e.printStackTrace(); } } } getStart/hello.html 0100644 0074524 0012666 00000000365 06604453504 0016106 0 ustar 00jvolpe jinieast 0000254 0000004
getStart/policy 0100644 0074524 0012666 00000000121 06604453513 0015325 0 ustar 00jvolpe jinieast 0000254 0000004 grant { // Allow everything for now permission java.security.AllPermission; };