Package org.sonews.daemon
Klasse Connections
java.lang.Object
org.sonews.daemon.DaemonRunner
org.sonews.daemon.Connections
- Alle implementierten Schnittstellen:
Runnable,DaemonRunnable
Daemon thread collecting all NNTPConnection instances. The thread checks
periodically if there are stale/timed out connections and removes and purges
them properly.
- Seit:
- sonews/0.5.0
- Autor:
- Christian Lins
-
Feldübersicht
FelderModifizierer und TypFeldBeschreibungprivate final Map<SocketChannel, NNTPConnection> private final List<NNTPConnection> private static final Connectionsprivate final org.slf4j.LoggerVon Klasse geerbte Felder org.sonews.daemon.DaemonRunner
daemon -
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungvoidadd(NNTPConnection conn) Adds the given NNTPConnection to the Connections management.get(SocketChannel channel) static Connectionsvoidrun()Run loops.Von Klasse geerbte Methoden org.sonews.daemon.DaemonRunner
setDaemonVon Klasse geerbte Methoden java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitVon Schnittstelle geerbte Methoden org.sonews.daemon.DaemonRunnable
dispose
-
Felddetails
-
instance
-
connections
-
connByChannel
-
log
private final org.slf4j.Logger log
-
-
Konstruktordetails
-
Connections
private Connections()
-
-
Methodendetails
-
getInstance
- Gibt zurück:
- Active Connections instance.
-
add
Adds the given NNTPConnection to the Connections management.- Parameter:
conn-- Siehe auch:
-
get
- Parameter:
channel-- Gibt zurück:
- NNTPConnection instance that is associated with the given SocketChannel.
-
run
public void run()Run loops. Checks periodically for timed out connections and purged them from the lists.
-