com.evolveum.midpoint.schema
Interface ResultList<T>

All Superinterfaces:
java.util.Collection<T>, java.lang.Iterable<T>, java.util.List<T>
All Known Implementing Classes:
ResultArrayList

public interface ResultList<T>
extends java.util.List<T>

List with extensions to provide more information about the operation result.

This interface is intended to be used as a result of search or list operations. It contains the results as a normal list would contain, but it also provides more information about the result. E.g. It may return the total number of results that matched the query. The list itself may contain only subset of all objects, e.g. when constrained by paging request. This list result also total count, therefore appropriate GUI controls or progress bars can be displayed.

Author:
lazyman, Radovan Semancik

Method Summary
 java.lang.Integer getTotalResultCount()
           Returns total number of all objects that matched a search/list criteria.
 void setTotalResultCount(java.lang.Integer count)
           Sets total number of all objects that matched a search/list criteria.
 
Methods inherited from interface java.util.List
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArray
 

Method Detail

getTotalResultCount

java.lang.Integer getTotalResultCount()

Returns total number of all objects that matched a search/list criteria.

It may be different from the list size e.g. if paging control was used in the request.

totalResultCount may be null. This means that repository cannot determine the total number of results. Negative value must not be used.

Returns:
total number of all objects that matched a search/list criteria (or null).

setTotalResultCount

void setTotalResultCount(java.lang.Integer count)

Sets total number of all objects that matched a search/list criteria.

It may be different from the list size e.g. if paging control was used in the request.

totalResultCount may be null. This means that repository cannot determine the total number of results. Negative value must not be used.

Parameters:
count - total number of all objects that matched a search/list criteria (or null).


Copyright © 2012 evolveum. All Rights Reserved.