public PeerConnection(Flood theFlood, String remoteHost, int remotePort, String remoteId)
public PeerConnection()
  public PeerConnection(Flood theFlood, String remoteHost, int remotePort, String remoteId)  {    flood = theFlood;    localPeer = flood.localPeer;    hostname = remoteHost;    port = remotePort;    id = remoteId;    try    {      socketSelector = Selector.open();      socketChannel = SocketChannel.open();      socketChannel.configureBlocking( false );      socketChannel.register( socketSelector, socketChannel.validOps() );      socketChannel.connect( new InetSocketAddress( InetAddress.getByName( hostname ), port ) );    }    catch ( Exception e )    {      System.out.println( "Error connecting to (" + hostname + ":" + port + "): " + e );      disconnected = true;      return;    }    // register ourselves w/ the peer    {      Vector args = new Vector();      args.add( flood.Id() );      args.add( flood.localPeer.id );      args.add( new Integer( flood.localPeer.port ) );      SendMethod( RegisterMethodHandler.methodName, args );    }    // request some chunks    SendMethod( RequestChunkMapsMethodHandler.methodName, new Vector() );  }