public class RapidoidServerLoop extends AbstractEventLoop<TCPServer> implements TCPServer, TCPServerInfo
Modifier and Type | Field and Description |
---|---|
protected Protocol |
protocol |
selector
ownerThread, status
Constructor and Description |
---|
RapidoidServerLoop(Protocol protocol,
Class<? extends DefaultExchange<?,?>> exchangeClass,
Class<? extends RapidoidHelper> helperClass) |
Modifier and Type | Method and Description |
---|---|
protected void |
acceptOP(SelectionKey key) |
protected void |
beforeLoop() |
protected void |
doProcessing() |
Protocol |
getProtocol() |
TCPServerInfo |
info() |
long |
messagesProcessed() |
RapidoidConnection |
newConnection() |
void |
process(RapidoidConnection conn) |
String |
process(String input) |
TCPServer |
shutdown() |
TCPServer |
start() |
connectOP, failedOP, insideLoop, readOP, writeOP
afterLoop, assertStatus, checkOnSameThread, onSameThread, run, stopLoop, waitToStart, waitToStop
protected final Protocol protocol
public RapidoidServerLoop(Protocol protocol, Class<? extends DefaultExchange<?,?>> exchangeClass, Class<? extends RapidoidHelper> helperClass)
protected void acceptOP(SelectionKey key) throws IOException
acceptOP
in class AbstractEventLoop<TCPServer>
IOException
protected void doProcessing()
doProcessing
in class AbstractEventLoop<TCPServer>
protected final void beforeLoop()
beforeLoop
in class AbstractLoop<TCPServer>
public TCPServer start()
start
in interface org.rapidoid.activity.Activity<TCPServer>
start
in class AbstractLoop<TCPServer>
public TCPServer shutdown()
shutdown
in interface org.rapidoid.activity.Activity<TCPServer>
shutdown
in class AbstractLoop<TCPServer>
public RapidoidConnection newConnection()
public void process(RapidoidConnection conn)
public Protocol getProtocol()
public TCPServerInfo info()
public long messagesProcessed()
messagesProcessed
in interface TCPServerInfo
Copyright © 2014–2015 Nikolche Mihajlovski. All rights reserved.