/*
 * Created on 2004-6-19
 *
 * To change the template for this generated file go to
 * Window - Preferences - Java - Code Generation - Code and Comments
 */
package workflow.test;

import java.io.BufferedInputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.net.Socket;
import java.rmi.MarshalledObject;

import org.huihoo.willow.client.Naming;

/**
 * @author reic
 *
 * To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Generation - Code and Comments
 */
public class NamingTest
{

	public static void main(String[] args) throws Exception, IOException
	{
		Socket socket=new Socket("localhost",2126);
		BufferedInputStream bis = new BufferedInputStream(socket.getInputStream());
		ObjectInputStream in = new ObjectInputStream(bis);
		MarshalledObject stub = (MarshalledObject) in.readObject();
		Naming server = (Naming) stub.get();
		
		System.err.println("server="+server);
		socket.close();
	}
}
