hello, i have a program to write and make ammendments to but iam hopeless at java, can anyone help me?
this file i think creates an interface between the cline t and the server, i have been told that only one of the interfaces has been created and i have to create the other, and that its not a lot of code. can anyone tell me how to do this?
/** * Remote interface for a chat service. * * @author Nick Efford * @version 1.0 (2002-11-06) */
public interface ChatService extends Remote {
/** * Registers a client with the chat service. * * @param client ChatClient to be registered * @return true if registration succeeds, false if client * is already registered * @throws RemoteException if remote invocation fails */
public boolean addClient(ChatClient client) throws RemoteException;
/** * Removes a client, so they will no longer receive messages. * * @param client ChatClient to be removed * @return true if removal succeeds, false if client wasn't * already registered * @throws RemoteException if remote invocation fails */
public boolean removeClient(ChatClient client) throws RemoteException;
/** * Distributes a message from one client to all clients * registered with the service. * * @param sender ChatClient from whom message originates * @param message string of text to be sent to all clients * @throws ChatException if sender is not registered with service * @throws RemoteException if remote invocation fails */
public void sendMessage(ChatClient sender, String message) throws ChatException, RemoteException;