Constructor DocumentSourceItem
DocumentSourceItem(string, string, Func<CancellationToken, ValueTask<Stream>>, string?, long?, DateTimeOffset?, IReadOnlyDictionary<string, string>?)
One item a source yields. SP3 never interprets Path.
public DocumentSourceItem(string DocumentId, string MediaType, Func<CancellationToken, ValueTask<Stream>> OpenAsync, string? Path = null, long? SizeBytes = null, DateTimeOffset? LastModifiedUtc = null, IReadOnlyDictionary<string, string>? Metadata = null)
Parameters
DocumentIdstringStable within the source. The state row's key, with the source id.
MediaTypestringDrives registry resolution before the extension does.
OpenAsyncFunc<CancellationToken, ValueTask<Stream>>Called TWICE per document (hash pass, then extraction pass) and so MUST be re-openable. SHOULD return a seekable stream at position 0; a non-seekable one is buffered once below NonSeekableBufferLimitBytes and raises 6053 above it (spec 7.1).
PathstringThe originating path or handle, for diagnostics only.
SizeByteslong?Declared size, when the source knows it for free.
LastModifiedUtcDateTimeOffset?Declared mtime, when the source knows it for free.
MetadataIReadOnlyDictionary<string, string>Extra per-document facts a consumer wants carried through.