question: public void unRegister ( SocketChannel channel ) { if ( channel . isRegistered ( ) ) { SelectionKey key = channel . keyFor ( mReadSelector ) ; if ( key != null ) { key . cancel ( ) ; mReadRegisterMap . remove ( key ) ; mReadSelector . wakeup ( ) ; } key = channel . keyFor ( mWriteSelector ) ; if ( key != null ) { key . cancel ( ) ; mWriteRegisterMap . remove ( key ) ; mWriteSelector . wakeup ( ) ; } } }
target:  Cancel a SocketChannel register