Interface IOcrPageCollection
Collection of PDF pages
Namespace: IronOcr.OcrResults
Assembly: IronOcr.dll
Syntax
public interface IOcrPageCollection
IOcrPageCollection is the read-only contract for a set of OCR result pages. It lets code accept "the pages of a read" without binding to a concrete list type, so a method can take the pages of any OcrResult and enumerate them the same way.
The contract is a typed, read-only page collection: it extends IReadOnlyCollection<OcrResult.Page> and IEnumerable<OcrResult.Page>, so you get a Count and can foreach over OcrResult.Page items, but the collection is not meant to be mutated by consumers. The concrete implementor in IronOCR is OcrResultPagesCollection, the type OcrResult.Pages returns, so in practice you obtain an IOcrPageCollection simply by reading result.Pages.
Most code uses result.Pages directly and never names the interface. Type a parameter as IOcrPageCollection when you want a helper that processes pages from any source and stays easy to test, since a unit test can pass a stub collection of OcrResult.Page instead of running a real read. Either way, enumerate the pages and read each one through the OcrResult.Page members.
The OCR results objects example iterates the page collection, and the reading results how-to shows how to process each page.