Update PollingConfig maxRecords method to return PollingConfig (#1275)
This commit is contained in:
parent
ddff314020
commit
a95aa9e39e
1 changed files with 2 additions and 1 deletions
|
|
@ -146,12 +146,13 @@ public class PollingConfig implements RetrievalSpecificConfig {
|
|||
return this;
|
||||
}
|
||||
|
||||
public void maxRecords(int maxRecords) {
|
||||
public PollingConfig maxRecords(int maxRecords) {
|
||||
if (maxRecords > DEFAULT_MAX_RECORDS) {
|
||||
throw new IllegalArgumentException(
|
||||
"maxRecords must be less than or equal to " + DEFAULT_MAX_RECORDS + " but current value is " + maxRecords());
|
||||
}
|
||||
this.maxRecords = maxRecords;
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue