code: DownloadState query(int downloadId) {
      synchronized (currentRequests) {
        for (DownloadRequest request : currentRequests) {
          if (request.downloadId() == downloadId) {
            return request.downloadState();
          }
        }
      }
  
      return DownloadState.INVALID;
    }
docs: To check if the request is downloading according to download id.
  
  @param downloadId download id
  @return true if the request is downloading, otherwise return false