Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

EndpointAddressBuilder Class

A factory for producing new (immutable) endpoint addresses with specific property values.

System.Object
  System.ServiceModel.EndpointAddressBuilder

Namespace:  System.ServiceModel
Assemblies:   System.ServiceModel.Primitives (in System.ServiceModel.Primitives.dll)
  System.ServiceModel (in System.ServiceModel.dll)

public class EndpointAddressBuilder

The EndpointAddressBuilder type exposes the following members.

  NameDescription
Public methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsEndpointAddressBuilder()Initializes a new instance of the EndpointAddressBuilder class.
Public methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsEndpointAddressBuilder(EndpointAddress)Initializes a new instance of the EndpointAddressBuilder class from an existing endpoint address.
Top

  NameDescription
Public propertySupported by Portable Class LibrarySupported in .NET for Windows Store appsHeadersGets the list of address headers for the endpoints that the builder can create.
Public propertySupported in .NET for Windows Store appsIdentityGets or sets the identity for the endpoints that the builder can create.
Public propertySupported by Portable Class LibrarySupported in .NET for Windows Store appsUriGets or sets the URI for the endpoints that the builder can create.
Top

  NameDescription
Public methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsEquals(Object)Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetReaderAtExtensionsReturns the XML dictionary reader that contains the extensions of the endpoint address.
Public methodGetReaderAtMetadataReturns the reader that contains the metadata associated with the endpoint address.
Public methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodSetExtensionReaderSpecifies the XML dictionary reader that contains the extensions of the endpoint address.
Public methodSetMetadataReaderSpecifies the XML dictionary reader that contains the metadata associated with the endpoint address.
Public methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsToEndpointAddressCreates a new endpoint address initialized with the property values of the current endpoint address builder.
Public methodSupported by Portable Class LibrarySupported in .NET for Windows Store appsToStringReturns a string that represents the current object. (Inherited from Object.)
Top

The new endpoint address can have its property values initialized from the property values of an existing endpoint address using the EndpointAddressBuilder(EndpointAddress) constructor.

The endpoint addresses created can have their URI and identity values set using the Uri and Identity properties of the endpoint address builder. Note that EndpointAddress is an immutable class.

EndpointAddressBuilder eab = new EndpointAddressBuilder();
eab.Uri = new Uri("http://localhost/Uri");
eab.Headers.Add(AddressHeader.CreateAddressHeader("n", "ns", "val"));

eab.Identity = EndpointIdentity.CreateUpnIdentity("identity");

XmlDictionaryReader xdrExtensions = eab.GetReaderAtExtensions();

StringReader sr = new StringReader(@"<myExtension xmlns=""myExtNs"" />");
eab.SetExtensionReader(XmlDictionaryReader.CreateDictionaryReader(XmlReader.Create(sr)));

EndpointAddress ea = eab.ToEndpointAddress();

sr = new StringReader(@"<myMetadata xmlns=""myMetaNs"" />");
XmlDictionaryReader xdrMetaData = eab.GetReaderAtMetadata();

eab.SetMetadataReader(XmlDictionaryReader.CreateDictionaryReader(XmlReader.Create(sr)));

.NET Framework

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

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Portable Class Library

Supported in: Portable Class Library

.NET for Windows Store apps

Supported in: Windows 8

Supported in: Windows Phone 8.1

Supported in: Windows Phone Silverlight 8.1

Supported in: Windows Phone Silverlight 8

Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

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