⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rmiinterface.java

📁 一个rmi程序例子
💻 JAVA
字号:
import java.rmi.*;
import java.util.*;

/*
 * Created on 2006-6-5
 *
 * TODO To change the template for this generated file go to
 * Window - Preferences - Java - Code Style - Code Templates
 */

/**
 * @author lizhao
 * 
 * TODO To change the template for this generated type comment go to Window -
 * Preferences - Java - Code Style - Code Templates
 */
public interface RMIInterface extends Remote {

	/**
	 * A method to register a user on the remote server
	 * 
	 * @param name
	 *            the name of user the client want to register
	 * @param passWord
	 *            the password of the user the client want to register
	 * @return
	 * @throws RemoteException
	 */
	public String register(String name, String passWord) throws RemoteException;

	/**
	 * A method add a meeting with a guest to a registered user
	 * 
	 * @param hostName
	 *            to who the meeting will add
	 * @param passWord
	 *            the password of the user to who the meeting will add
	 * @param guestName
	 *            with who the meeting will be
	 * @param start
	 *            the start time of this meeting
	 * @param end
	 *            the end time of this meeting
	 * @param title
	 *            the title of this meeting
	 * @return
	 * @throws RemoteException
	 */
	public String addMeeting(String hostName, String passWord,
			String guestName, Date begin, Date over, String title)
			throws RemoteException;

	/**
	 * A method to query all the meetings added the a user in a interval
	 * 
	 * @param name
	 *            the name of user whose meeting will be queried
	 * @param passWord
	 *            the password of user whose meeting will be queried
	 * @param start
	 *            the start time of the interval to be queried
	 * @param end
	 *            the end time of the interval to be queried
	 * @return
	 * @throws RemoteException
	 */
	public String queryMeeting(String name, String passWord, Date begin,
			Date over) throws RemoteException;

	/**
	 * A method to delete a meeting of a user
	 * 
	 * @param name
	 *            the name of user whose meeting will be deleted
	 * @param passWord
	 *            the password of user whose meeting will be deleted
	 * @param title
	 *            the title of meeting to be deleted
	 * @return
	 * @throws RemoteException
	 */
	public String deleteMeeting(String name, String passWord, String title)
			throws RemoteException;

	/**
	 * To clear all the meetings of a user
	 * 
	 * @param name
	 *            the name of user whose meeting will be cleared
	 * @param passWord
	 *            the password of user whose meeting will be cleared
	 * @return
	 * @throws RemoteException
	 */
	public String clearMeeting(String name, String passWord)
			throws RemoteException;
}

⌨️ 快捷键说明

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