What is XDocument? [closed]
I am using linq to xml.
In this we load xml file as XDocument.Load("filename.xml")
.
What is this XDocument
?
XDocument is a .NET class which represents an XML Document in memory but with specific support for Linq. It is part of the System.Xml.Linq namespace. See msdn.
XDocument
is a class representing an XML document, providing LINQ-friendly behaviors and approaches.
It's System.Xml.XmlDocument
equivalent for the LINQ era.
In your case XDocument is a class which allows you to call the static method Load.
This Load method returns an instance of XDocument.
精彩评论