public abstract static class TestMailServer.MailServer extends Object implements Runnable
Modifier and Type | Class and Description |
---|---|
class |
TestMailServer.MailServer.MailHandler |
Modifier and Type | Field and Description |
---|---|
protected Set<String> |
assertions |
protected List<String> |
messages |
Constructor and Description |
---|
MailServer(int port) |
Modifier and Type | Method and Description |
---|---|
boolean |
assertReceived(String assertion) |
List<String> |
getMessages() |
int |
getPort() |
boolean |
isListening() |
protected abstract TestMailServer.MailServer.MailHandler |
mailHandler(Socket socket) |
void |
resetServer() |
void |
run() |
void |
stop() |
public MailServer(int port) throws IOException
IOException
public int getPort()
public boolean isListening()
public void resetServer()
public boolean assertReceived(String assertion)
protected abstract TestMailServer.MailServer.MailHandler mailHandler(Socket socket)
public void stop()