Commit 7a012f89 authored by tammam.alsoleman's avatar tammam.alsoleman

edit the interface IQuizService & create the client call back

parent 96224c91
package org.example.shared;
import java.rmi.Remote;
import java.rmi.RemoteException;
public interface IClientCallback extends Remote {
void onLeaderboardUpdate(String leaderboard) throws RemoteException;
}
\ No newline at end of file
......@@ -5,12 +5,9 @@ import java.rmi.RemoteException;
public interface IQuizService extends Remote {
String getRandomQuestion() throws RemoteException;
String submitAnswer(String studentName, String answer) throws RemoteException;
public String getRandomQuestion() throws RemoteException;
public String submitAnswer(String studentName, String answer) throws RemoteException;
public String getLeaderboard() throws RemoteException;
public String authenticateStudent(String studentName) throws RemoteException;
// Combined authentication + callback registration
String authenticateStudent(String studentName, IClientCallback callback) throws RemoteException;
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment