Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
XmlNamespaceMapping Class

XmlNamespaceMapping Class

Declares a mapping between a uniform resource identifier (URI) and a prefix.


Namespace:  System.Windows.Data
Assembly:  PresentationFramework (in PresentationFramework.dll)
XMLNS for XAML: http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation

public class XmlNamespaceMapping : ISupportInitialize
<XmlNamespaceMapping .../>

The XmlNamespaceMapping type exposes the following members.

Public methodXmlNamespaceMapping()Initializes a new instance of the XmlNamespaceMapping class.
Public methodXmlNamespaceMapping(String, Uri)Initializes a new instance of the XmlNamespaceMapping class with the specified prefix and uniform resource identifier (URI).

Public propertyPrefixGets or sets the prefix to use in Extensible Application Markup Language (XAML).
Public propertyUriGets or sets the Uri of the namespace for which to create a mapping.

Public methodEqualsReturns a value that indicates whether this XmlNamespaceMapping is equivalent to the specified instance. (Overrides Object.Equals(Object).)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetHashCodeReturns the hash code for this XmlNamespaceMapping. (Overrides Object.GetHashCode().)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)

Public operatorStatic memberEqualityPerforms equality comparison by value.
Public operatorStatic memberInequalityPerforms inequality comparison by value.

Explicit interface implemetationPrivate methodISupportInitialize.BeginInitThis member supports the Windows Presentation Foundation (WPF) infrastructure and is not intended to be used directly from your code.
Explicit interface implemetationPrivate methodISupportInitialize.EndInitThis member supports the Windows Presentation Foundation (WPF) infrastructure and is not intended to be used directly from your code.

To declare a mapping between a URI and a prefix, create an XmlNamespaceMapping class and add it to an XmlNamespaceMappingCollection object that is used as the XmlNamespaceManager for a binding.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
© 2015 Microsoft