private void checkPausedOrCanceled(State state) throws StopRequest {
  if (mService.getControl() == DownloaderService.CONTROL_PAUSED) {
    int status=mService.getStatus();
switch (status) {
case DownloaderService.STATUS_PAUSED_BY_APP:
      throw new StopRequest(mService.getStatus(),"download paused");
  }
}
}

private void checkPausedOrCanceled ( State state ) throws StopRequest { if ( mService . getControl ( ) == DownloaderService . CONTROL_PAUSED ) { int status = mService . getStatus ( ) ; switch ( status ) { case DownloaderService . STATUS_PAUSED_BY_APP : throw new StopRequest ( mService . getStatus ( ) , "download paused" ) ; } } }
check if the download has been paused or canceled , stopping the request appropriately if it has been .
