Interface IDocumentLoader
Loads documents from a given source (file path, URL, etc.) and returns structured DoclingDocument objects. Implement this interface for each document type (PDF, DOCX, HTML, plain text, etc.).
public interface IDocumentLoader
Methods
LoadAsync(string, CancellationToken)
Loads one or more documents from the specified source. A single source may yield multiple documents (e.g., a ZIP archive or a directory).
Task<IReadOnlyList<DoclingDocument>> LoadAsync(string source, CancellationToken cancellationToken = default)
Parameters
sourcestringFile path, URL, or other source identifier.
cancellationTokenCancellationTokenCancellation token.
Returns
- Task<IReadOnlyList<DoclingDocument>>
A list of loaded documents.