Class DocumentReadOptions
Options controlling how a reader materializes a document. This options bag grows additively; the IDocumentReader interface itself never changes within a major version.
public sealed class DocumentReadOptions
- Inheritance
-
DocumentReadOptions
- Inherited Members
Constructors
Properties
- Limits
Gets or sets the resource caps applied while reading, or null for no caps.
- Password
Gets or sets the password used to decrypt an encrypted document, or null.
Supplying a password for an unencrypted document is harmless and ignored. Omitting one for an encrypted document raises DocumentEncryptedException; supplying the wrong one raises InvalidPasswordException. Neither message repeats the value.
This is a string rather than a
SecureStringdeliberately:SecureStringis documented by the platform as offering no protection on non-Windows runtimes, and every crypto API this feeds takes a byte array anyway. DocWright zeroes the material it derives; it cannot zero the caller's string.
- StrictMode
Gets or sets a value indicating whether unsupported content aborts the read (true) instead of being reported and preserved or skipped (false, the default).