在CMD里compile 这个文件时,总是说找不到符号(implements HelloWorld),如下:package rmi.iiop;
import java.rmi.RemoteException;
import javax.rmi.PortableRemoteObject;public class HelloWorldImpl extends PortableRemoteObject
implements HelloWorld { public HelloWorldImpl() throws Exception, RemoteException { super();
} public String getGreetings() throws RemoteException {
return "Hello World!";
} public String getGreetings(String userName) throws RemoteException {
return ("Hello " + userName + "!");
}
}HelloWorld.java (这个已编译成功)package rmi.iiop;import java.rmi.Remote;
import java.rmi.RemoteException;
public interface HelloWorld extends Remote { public String getGreetings() throws RemoteException; public String getGreetings(String userName) throws RemoteException;
}