Changeset 2692
- Timestamp:
- 03/13/13 11:05:15 (11 years ago)
- Location:
- SRUServer/trunk/src/main/java/eu/clarin/sru/server
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
SRUServer/trunk/src/main/java/eu/clarin/sru/server/SRURequestImpl.java
r2688 r2692 66 66 private CQLNode query; 67 67 private String rawQuery; 68 private int startRecord = -1;68 private int startRecord = DEFAULT_START_RECORD; 69 69 private int maximumRecords = -1; 70 70 private String recordSchemaName; … … 76 76 private CQLNode scanClause; 77 77 private String rawScanClause; 78 private int responsePosition = -1;78 private int responsePosition = DEFAULT_RESPONSE_POSITION; 79 79 private int maximumTerms = -1; 80 80 … … 411 411 412 412 413 int getRawStartRecord() {414 return startRecord;415 }416 417 418 413 int getRawMaximumRecords() { 419 414 return maximumRecords; … … 423 418 String getRawScanClause() { 424 419 return rawScanClause; 425 }426 427 428 int getRawResponsePosition() {429 return responsePosition;430 420 } 431 421 … … 503 493 @Override 504 494 public int getStartRecord() { 505 return (startRecord > 0) ? startRecord : DEFAULT_START_RECORD;495 return startRecord; 506 496 } 507 497 … … 563 553 @Override 564 554 public int getResponsePosition() { 565 return (responsePosition >= 0) 566 ? responsePosition : DEFAULT_RESPONSE_POSITION; 555 return responsePosition; 567 556 } 568 557 -
SRUServer/trunk/src/main/java/eu/clarin/sru/server/SRUServer.java
r2688 r2692 353 353 // check, of startRecord position is greater than total record set 354 354 if ((result.getTotalRecordCount() >= 0) && 355 (request.get RawStartRecord() > 0) &&356 (request.get RawStartRecord() > result.getTotalRecordCount())) {355 (request.getStartRecord() > 1) && 356 (request.getStartRecord() > result.getTotalRecordCount())) { 357 357 throw new SRUException( 358 358 SRUConstants.SRU_FIRST_RECORD_POSITION_OUT_OF_RANGE);
Note: See TracChangeset
for help on using the changeset viewer.