@Override public List<IBaseResource> getResources(int theFromIndex, int theToIndex) { return getList(); // indexes are ignored for this provider type }
/** * Constructor * * @param theResultsInThisPage The complete list of results in the current page. Must not be null. * @param theSearchId The ID for the search. Note that you should also populate {@link #setNextPageId(String)} and {@link #setPreviousPageId(String)} if these are known. Must not be <code>null</code> or blank. * @param thePageId The ID for the current page. Note that you should also populate {@link #setNextPageId(String)} and {@link #setPreviousPageId(String)} if these are known. Must not be <code>null</code> or blank. * @param theTotalResults The total number of result (if this is known), or <code>null</code> * @see #setNextPageId(String) * @see #setPreviousPageId(String) */ public BundleProviderWithNamedPages(List<IBaseResource> theResultsInThisPage, String theSearchId, String thePageId, Integer theTotalResults) { super(theResultsInThisPage, theSearchId); Validate.notNull(theResultsInThisPage, "theResultsInThisPage must not be null"); Validate.notBlank(thePageId, "thePageId must not be null or blank"); setCurrentPageId(thePageId); setSize(theTotalResults); }
/** * Constructor * * @param theResultsInThisPage The complete list of results in the current page. Must not be null. * @param theSearchId The ID for the search. Note that you should also populate {@link #setNextPageId(String)} and {@link #setPreviousPageId(String)} if these are known. Must not be <code>null</code> or blank. * @param thePageId The ID for the current page. Note that you should also populate {@link #setNextPageId(String)} and {@link #setPreviousPageId(String)} if these are known. Must not be <code>null</code> or blank. * @param theTotalResults The total number of result (if this is known), or <code>null</code> * @see #setNextPageId(String) * @see #setPreviousPageId(String) */ public BundleProviderWithNamedPages(List<IBaseResource> theResultsInThisPage, String theSearchId, String thePageId, Integer theTotalResults) { super(theResultsInThisPage, theSearchId); Validate.notNull(theResultsInThisPage, "theResultsInThisPage must not be null"); Validate.notBlank(thePageId, "thePageId must not be null or blank"); setCurrentPageId(thePageId); setSize(theTotalResults); }
@Override public List<IBaseResource> getResources(int theFromIndex, int theToIndex) { return getList(); // indexes are ignored for this provider type }