helloimpl.java

来自「有关于rmi和 rmi-iiop远程服务器调用的几个实例 包括Fibonacci」· Java 代码 · 共 33 行

JAVA
33
字号
import java.rmi.RemoteException;
import java.rmi.server.RMIClientSocketFactory;
import java.rmi.server.RMIServerSocketFactory;
import java.rmi.server.UnicastRemoteObject;
import java.util.Stack;


//Service Class
public class helloImpl extends UnicastRemoteObject implements hello {
 	public helloImpl() throws RemoteException {
		// TODO Auto-generated constructor stub
	}

	public helloImpl(int arg0) throws RemoteException {
		super(arg0);
		// TODO Auto-generated constructor stub
	}

	public helloImpl(int arg0, RMIClientSocketFactory arg1,
			RMIServerSocketFactory arg2) throws RemoteException {
		super(arg0, arg1, arg2);
		// TODO Auto-generated constructor stub
	}
	public double hello(String exp) throws RemoteException
	{   
        Eval eval = new Eval();
		double result = eval.eval(exp); 

		return  result;
	}

}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?