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

📄 callbackimpl.java

📁 JAVA程序设计导论那本书上的一些源代码. 在学那本书的下来的
💻 JAVA
字号:
import java.rmi.*;import java.rmi.server.*;public class CallBackImpl extends UnicastRemoteObject    implements CallBack {  // The client will be called by the server through callback  private TicTacToeClientRMI thisClient;  /** Constructor */  public CallBackImpl(Object client) throws RemoteException {    thisClient = (TicTacToeClientRMI)client;  }  /** The server notifies the client for taking a turn */  public void takeTurn(boolean turn) throws RemoteException {    thisClient.setMyTurn(turn);  }  /** The server sends a message to be displayed by the client */  public void notify(String message) throws RemoteException {    thisClient.setMessage(message);  }  /** The server notifies a client of the other player's move */  public void mark(int row, int column, char token)      throws RemoteException {    thisClient.mark(row, column, token);  }}

⌨️ 快捷键说明

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