public synchronized void clear()
{
logger.debug("removing all " + queue.size()
+ " messages for: " + server);
for (Iterator i = queue.iterator(); i.hasNext();) {
ClientMessage msg = (ClientMessage)i.next();
if (msg.listener != null) {
msg.listener.exceptionThrown
(new IOException(Plugin.tr("Server disconnected")));
}
}