DocumentSet Constructor (XmlResolver, XmlReaderSettings, bool)DocumentSet Constructor (XmlResolver, XmlReaderSettings, Boolean)DocumentSet Constructor (XmlResolver^, XmlReaderSettings^, bool)
- XmlPrime 3.0
- Other Versions ▼
Syntax
Public Sub New ( _ resolver As System.Xml.XmlResolver, _ settings As System.Xml.XmlReaderSettings, _ threadSafe As Boolean _ )
public DocumentSet( System.Xml.XmlResolver resolver, System.Xml.XmlReaderSettings settings, bool threadSafe )
public: DocumentSet( System.Xml::XmlResolver^ resolver, System.Xml::XmlReaderSettings^ settings, bool threadSafe )
Parameters
- resolver
Type: System.Xml.XmlResolverSystem.Xml.XmlResolverSystem.Xml::XmlResolver^
The resolver to use to resolve resources.
- settings
Type: System.Xml.XmlReaderSettingsSystem.Xml.XmlReaderSettingsSystem.Xml::XmlReaderSettings^
The settings to use to parse documents.
- threadSafe
Type: System.BooleanSystem.BooleanSystem::Boolean
true
True
true
if the document set should be thread-safe; otherwisefalse
False
false
.
Exceptions
Exception | Condition |
ArgumentExceptionArgumentExceptionArgumentException | The NameTableNameTableNameTable of settings is null
a null reference (Nothing in Visual Basic)
nullptr . |
ArgumentNullExceptionArgumentNullExceptionArgumentNullException | settings is null
a null reference (Nothing in Visual Basic)
nullptr . |
Remarks
resolver is used to resolve all resources. Any documents are first resolved as resources, and then parsed with an XmlReaderXmlReaderXmlReader initialized using the XmlReaderSettingsXmlReaderSettingsXmlReaderSettings provided. The resolver on the XmlReader settings is replaced with one which retrieves resources directly from the document set.
If the unparsed-text
function is not used then consider constructing the DocumentSetDocumentSetDocumentSet
with an XmlReaderDocumentResolverXmlReaderDocumentResolverXmlReaderDocumentResolver and no IResourceResolverIResourceResolverIResourceResolver to avoid caching
the raw contents of every document retrieved.
This is equivalent to constructing the document set with a UnparsedTextDocumentResolverUnparsedTextDocumentResolverUnparsedTextDocumentResolver and a XmlResourceResolverXmlResourceResolverXmlResourceResolver for the document and resource resolvers respectively.
The NameTableNameTableNameTable property is set to that of the settings instance, which
must not be null
a null reference (Nothing
in Visual Basic)
nullptr
.