Class I2PTunnelDCCClient

All Implemented Interfaces:
Runnable, EventDispatcher

public class I2PTunnelDCCClient extends I2PTunnelClientBase
A standard client, using an existing socket manager. Targets a single destination and port. Naming resolution is delayed until connect time.
Since:
0.8.9
  • Field Details

  • Constructor Details

    • I2PTunnelDCCClient

      public I2PTunnelDCCClient(String dest, int localPort, int remotePort, Logging l, I2PSocketManager sktMgr, EventDispatcher notifyThis, I2PTunnel tunnel, long clientId) throws IllegalArgumentException
      As of 0.9.20 this is fast, and does NOT connect the manager to the router, or open the local socket. You MUST call startRunning() for that.
      Parameters:
      dest - the target, presumably b32
      localPort - if 0, use any port, get actual port selected with getLocalPort()
      Throws:
      IllegalArgumentException - if the I2PTunnel does not contain valid config to contact the router
  • Method Details

    • clientConnectionRun

      protected void clientConnectionRun(Socket s)
      Accept one connection only.
      Specified by:
      clientConnectionRun in class I2PTunnelClientBase
    • getExpires

      public long getExpires()
    • getDest

      public String getDest()
    • getRemotePort

      public int getRemotePort()
    • stop

      public void stop()
      Stop listening for new sockets. We can't call super.close() as it kills all sockets in the sockMgr