public boolean isStopRequested(){
  if (stopRequested.get() == true)   return true;
 else   return false;
}

public boolean isStopRequested ( ) { if ( stopRequested . get ( ) == true ) return true ; else return false ; }
check the status of the stop request flag .
