@SuppressLint("Assert") void release(){
  assert (mProcessingThread.getState() == State.TERMINATED);
  mDetector.release();
  mDetector=null;
}

@ SuppressLint ( "Assert" ) void release ( ) { assert ( mProcessingThread . getState ( ) == State . TERMINATED ) ; mDetector . release ( ) ; mDetector = null ; }
releases the underlying receiver . this is only safe to do after the associated thread has completed , which is managed in camera source ' s release method above .
