Interface Limit<T>
- Type Parameters:
T
-
- All Superinterfaces:
Executor<T>
- All Known Subinterfaces:
Filter<T>
,OrderByFieldOrLimit<T>
,OrderByOperation<T>
,Query<T>
,ScoredFilter<T>
- API:
- This is a public API.
-
Method Summary
-
Method Details
-
limit
Limits the result to the given sizeExample:
import workflow.business.data.Dossier; List<Dossier> result = ivy.repo.search(Dossier.class) .limit(100) .execute() .getAll();
If you do not specify a limit then the maximum number of results that are returned is 10.
The value of parameter
size
must be smaller than the value of the index settingindex.max_result_window
(default value is 10000). If you specify a higher value you will receive an error.- Parameters:
size
- the maximum number of results to return.size
must be smaller thanindex.max_result_window
- Returns:
- execute operation
- See Also:
- API:
- This public API is available in IvyScript and Java. It has the visibility ADVANCED.
-
limit
Limits the result to the given from position and sizeExample:
import workflow.business.data.Dossier; List<Dossier> result = ivy.repo.search(Dossier.class) .limit(900, 100) .execute() .getAll();
If you do not use a limit method then the maximum number of results that are returned is 10.
The value of parameter
from
plus the value of parametersize
must be smaller than the value of the index settingindex.max_result_window
(default value is 10000). If you specify higher values you will receive an error.- Parameters:
from
- the start index of the first result to return.from
+size
must be smaller thanindex.max_result_window
size
- the maximum number of results to return.from
+size
must be smaller thanindex.max_result_window
- Returns:
- execute operation
- See Also:
- API:
- This public API is available in IvyScript and Java. It has the visibility ADVANCED.
-