Are methods such as XContainer.Elements, XContainer.Nodes etc also considered Linq to XML query operators?
Book uses different terms for Linq-to-XML methods/properties defined in classes XObject
, XNode
, XElement
etc ( such as XContainer.Elements
, XContainer.Nodes
, XObject.Document
... ) and for extension methods define开发者_JS百科d in Extensions
class. For former it uses the term methods, while with extension methods it uses the term query operators.
Is there a particular reason why author uses two different terms or are XContainer.Elements
, XContainer.Nodes
etc also considered Linq-to-XML query operators?
Thank you
Ultimately I doubt that these terms are specified anywhere in a particularly definitive way - and I wouldn't worry too much about it.
I wouldn't be surprised to see the author using the terms inconsistently themselves. I'd be even less surprised if that were the case and the author turned out to be me ;)
I'm not sure which book you are refering to, but the Elements/Nodes/etc methods are considered Axis Methods (http://msdn.microsoft.com/en-us/library/bb387099.aspx). I would think the query operators would be things like Select/Where/OrderBy regardless of whether they exist directly on the type in question or if they were static extension methods.
精彩评论