private boolean addSingleResult(OSQLAsynchQuery<ODocument> request, OBasicCommandContext ctx, ORecord record) {
    if (((OBasicCommandContext) context).addToUniqueResult(record)) {
      request.getResultListener().result(record);
      long currentCount = ctx.getResultsProcessed().incrementAndGet();
      long limitValue = limitFromProtocol;
      if (limit != null) {
        limitValue = limit.num.getValue().longValue();
      }
      if (limitValue > -1 && limitValue <= currentCount) {
        return false;
      }
    }
    return true;
  }
private boolean addSingleResult(OSQLAsynchQuery<ODocument> request, OBasicCommandContext ctx, ORecord record) {
    if (((OBasicCommandContext) context).addToUniqueResult(record)) {
      request.getResultListener().result(record);
      long currentCount = ctx.getResultsProcessed().incrementAndGet();
      long limitValue = limitFromProtocol;
      if (limit != null) {
        limitValue = limit.num.getValue().longValue();
      }
      if (limitValue > -1 && limitValue <= currentCount) {
        return false;
      }
    }
    return true;
  }
private boolean addSingleResult ( OSQLAsynchQuery < ODocument > request , OBasicCommandContext ctx , ORecord record ) { if ( ( ( OBasicCommandContext ) context ) . addToUniqueResult ( record ) ) { request . getResultListener ( ) . result ( record ) ; long currentCount = ctx . getResultsProcessed ( ) . incrementAndGet ( ) ; long limitValue = limitFromProtocol ; if ( limit != null ) { limitValue = limit . num . getValue ( ) . longValue ( ) ; } if ( limitValue > - 1 && limitValue <= currentCount ) { return false ; } } return true ; }
@param request
@param ctx
@param record

@return false if limit was reached
@param request @param ctx @param record