Open KBKrause opened 7 years ago
Exception is first thrown in GUIProxy.
@Override
public void update(String theUpdate) throws ConnectionFailedException
{
if (connToIns.sendString(theUpdate) == false)
{
throw new ConnectionFailedException();
}
}
This function is called by GUI when it is notifying all of its observers.
@Override
public void notifyObservers(String updateText)
{
for (InstructorObserver io : observers)
{
try
{
io.update(updateText);
}
catch(ChemberryException ex)
{
ex.printStackTrace();
}
}
}
So I think the exception handling should happen in GUI.
Exception handling will happen in GUI. Main thread of execution listens for signal from instructor. Signal failing to arrive will come later. GUI will use a listening proxy.
public class GUIListeningProxy extends ServerProxy
{
}
handleRequest
will only listen for the "d:esync" token.
commit 83f15d6f8fac115fc594af98dbabb357d7cca70c Client must account for instructor connection closing prematurely.