gozirra-ws/src/main/java/com/hi3project/vineyard/comm/stomp/gozirraws/Server.java
public void close( int port ) {
    for (Iterator i = _listeners.keySet().iterator(); i.hasNext(); ) {
      Object k = i.next();
      Object s = _listeners.get(k);
      if (s instanceof SocketHandler) {
        SocketHandler sh = (SocketHandler)s;
        if (port == -1 || sh.isPort( port )) {
          sh.interrupt();
          sh.close();
          _transactions.remove( s );
          _listeners.remove( k );
        }
      }
    }
  }
public void close( int port ) {
    for (Iterator i = _listeners.keySet().iterator(); i.hasNext(); ) {
      Object k = i.next();
      Object s = _listeners.get(k);
      if (s instanceof SocketHandler) {
        SocketHandler sh = (SocketHandler)s;
        if (port == -1 || sh.isPort( port )) {
          sh.interrupt();
          sh.close();
          _transactions.remove( s );
          _listeners.remove( k );
        }
      }
    }
  }
public void close ( int port ) { for ( Iterator i = _listeners . keySet ( ) . iterator ( ) ; i . hasNext ( ) ; ) { Object k = i . next ( ) ; Object s = _listeners . get ( k ) ; if ( s instanceof SocketHandler ) { SocketHandler sh = ( SocketHandler ) s ; if ( port == - 1 || sh . isPort ( port ) ) { sh . interrupt ( ) ; sh . close ( ) ; _transactions . remove ( s ) ; _listeners . remove ( k ) ; } } } }
Closes a port.  All connections on this port will be closed.

@param port The port to close.  A value of less than -1 closes all ports
Closes a port . All connections on this port will be closed .