FileDocCategorySizeDatePackage
DateClient.javaAPI DocExample587Sun Mar 14 13:09:42 GMT 2004darwinsys.distdate

DateClient

public class DateClient extends Object

Fields Summary
protected static RemoteDate
netConn
The local proxy for the service.
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] args)


	     
		try {
			netConn = (RemoteDate)Naming.lookup(RemoteDate.LOOKUPNAME);
			Date today = netConn.getRemoteDate();
			System.out.println(today.toString()); // Could use a DateFormat...
		} catch (Exception e) {
			System.err.println("RemoteDate exception: " + e.getMessage());
			e.printStackTrace();
		}