| It can be quite time consuming to enumerate of the entire result list, validating each document and removing unwanted one. To improve performance, it is recommended you do this action in batches.
In most web pages, search results are usually return in batches of 10 or so. You can take advantage of this by only validating up to the required amount. Therefore on the first page, you only validate until you have 10 validated documents. On the next page, you validate the next 10, and so on, and so on. |