Strumenti Utente

Strumenti Sito


lpr-b:mainbattitore
package astaRMI;
 
import java.rmi.*;
import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;
 
public class ServerAsta {
 
	public static void main(String[] args) {
 
		Battitore b = null;
		try {
			b = new Battitore();
		} catch (RemoteException e2) {
			// TODO Auto-generated catch block
			e2.printStackTrace();
		}
		Registry reg = null; 
 
		try {
			reg = LocateRegistry.createRegistry(Registry.REGISTRY_PORT);
		} catch (RemoteException e1) {
			// TODO Auto-generated catch block
			e1.printStackTrace();
		}
		try {
			reg.rebind("battitore", b);
		} catch (AccessException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (RemoteException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
 
	}
 
}
lpr-b/mainbattitore.txt · Ultima modifica: 07/12/2007 alle 09:56 (17 anni fa) da Marco Danelutto

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki