public void close(){
synchronized (this) {
    if (channel != null) {
      try {
        channel.close();
      }
 catch (      Exception ex) {
      }
      channel=null;
    }
    if (m_out != null) {
      m_out.shutdown();
      m_out=null;
    }
    if (m_in != null) {
      m_in.shutdown();
      m_in=null;
    }
  }
  List<TcpRequest> ls=new ArrayList<>(requestMap.values());
  for (  TcpRequest tr : ls) {
    tr.weekup();
  }
}

public void close ( ) { synchronized ( this ) { if ( channel != null ) { try { channel . close ( ) ; } catch ( Exception ex ) { } channel = null ; } if ( m_out != null ) { m_out . shutdown ( ) ; m_out = null ; } if ( m_in != null ) { m_in . shutdown ( ) ; m_in = null ; } } List < TcpRequest > ls = new ArrayList < > ( requestMap . values ( ) ) ; for ( TcpRequest tr : ls ) { tr . weekup ( ) ; } }
close the packet handler
