nerdexam
Microsoft

70-516 · Question #197

You use Microsoft .NET Framework 4.0 to develop an application. You use the XmlReader class to load XML from a location that you do not control. You need to ensure that loading the XML will not load…

The correct answer is C. XmlReaderSettings settings = new XmlReaderSettings(). CheckCharacters Gets or sets a value indicating whether to do character checking. ConformanceLevel Gets or sets the level of conformance which the XmlReader will comply. ValidationType Gets or sets a value indicating whether the XmlReader will perform validation or type…

Consuming and Exposing Data

Question

You use Microsoft .NET Framework 4.0 to develop an application. You use the XmlReader class to load XML from a location that you do not control. You need to ensure that loading the XML will not load external resources that are referenced in the XML. Which code segment should you use?

Options

  • AXmlReaderSettings settings = new XmlReaderSettings();
  • BXmlReaderSettings settings = new XmlReaderSettings();
  • CXmlReaderSettings settings = new XmlReaderSettings();
  • DXmlReaderSettings settings = new XmlReaderSettings();

How the community answered

(24 responses)
  • A
    4% (1)
  • B
    8% (2)
  • C
    71% (17)
  • D
    17% (4)

Explanation

CheckCharacters Gets or sets a value indicating whether to do character checking. ConformanceLevel Gets or sets the level of conformance which the XmlReader will comply. ValidationType Gets or sets a value indicating whether the XmlReader will perform validation or type assignment when reading. XmlResolver Sets the XmlResolver used to access external documents. XmlReaderSettings Class

Topics

#XmlReader#XmlReaderSettings#external resources#security

Community Discussion

No community discussion yet for this question.

Full 70-516 Practice