Export (0) Print
Expand All

XNamespace.Equals Method

Determines whether the specified XNamespace is equal to the current XNamespace.

Namespace:  System.Xml.Linq
Assembly:  System.Xml.Linq (in System.Xml.Linq.dll)

public override bool Equals(
	Object obj
)

Parameters

obj
Type: System.Object
The XNamespace to compare to the current XNamespace.

Return Value

Type: System.Boolean
A Boolean that indicates whether the specified XNamespace is equal to the current XNamespace.

For two XNamespace objects to be equal, they must have the same URI.

The following example compares two namespaces that refer to the same URI.


StringBuilder output = new StringBuilder();
XNamespace aw = "http://www.adventure-works.com";
output.Append(aw == "http://www.adventure-works.com" + Environment.NewLine);

OutputTextBlock.Text = output.ToString();


Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1, Windows Phone OS 7.0

XNA Framework

Supported in: Xbox 360, Windows Phone OS 7.0

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show:
© 2014 Microsoft