Upravit

Sdílet prostřednictvím


EndpointAddress.ReadFrom Method

Definition

Reads an endpoint address from a specified XML reader.

Overloads

ReadFrom(XmlDictionaryReader)

Reads an endpoint address from a specified XML dictionary reader.

ReadFrom(AddressingVersion, XmlDictionaryReader)

Reads an endpoint address for a specified address version from a specified XML dictionary reader.

ReadFrom(AddressingVersion, XmlReader)

Reads an endpoint address for a specified address version from a specified XML reader.

ReadFrom(XmlDictionaryReader, XmlDictionaryString, XmlDictionaryString)

Reads an endpoint address with a specified qualified name from a specified XML dictionary reader.

ReadFrom(AddressingVersion, XmlDictionaryReader, XmlDictionaryString, XmlDictionaryString)

Reads an endpoint address for a specified address version with a specified qualified name from a specified XML dictionary reader.

ReadFrom(AddressingVersion, XmlReader, String, String)

Reads an endpoint address for a specified address version with a specified qualified name from a specified XML reader.

ReadFrom(XmlDictionaryReader)

Source:
EndpointAddress.cs
Source:
EndpointAddress.cs

Reads an endpoint address from a specified XML dictionary reader.

public:
 static System::ServiceModel::EndpointAddress ^ ReadFrom(System::Xml::XmlDictionaryReader ^ reader);
public static System.ServiceModel.EndpointAddress ReadFrom (System.Xml.XmlDictionaryReader reader);
static member ReadFrom : System.Xml.XmlDictionaryReader -> System.ServiceModel.EndpointAddress
Public Shared Function ReadFrom (reader As XmlDictionaryReader) As EndpointAddress

Parameters

reader
XmlDictionaryReader

The XmlDictionaryReader from which the endpoint address is obtained.

Returns

The EndpointAddress read from the XML dictionary reader.

Examples

The following code shows how to read an endpoint address from a XML dictionary reader.

XmlDictionaryReader reader = (XmlDictionaryReader) XmlDictionaryReader.Create("addressdata.xml");
EndpointAddress createdEA = EndpointAddress.ReadFrom(reader);

Applies to

ReadFrom(AddressingVersion, XmlDictionaryReader)

Source:
EndpointAddress.cs
Source:
EndpointAddress.cs

Reads an endpoint address for a specified address version from a specified XML dictionary reader.

public:
 static System::ServiceModel::EndpointAddress ^ ReadFrom(System::ServiceModel::Channels::AddressingVersion ^ addressingVersion, System::Xml::XmlDictionaryReader ^ reader);
public static System.ServiceModel.EndpointAddress ReadFrom (System.ServiceModel.Channels.AddressingVersion addressingVersion, System.Xml.XmlDictionaryReader reader);
static member ReadFrom : System.ServiceModel.Channels.AddressingVersion * System.Xml.XmlDictionaryReader -> System.ServiceModel.EndpointAddress
Public Shared Function ReadFrom (addressingVersion As AddressingVersion, reader As XmlDictionaryReader) As EndpointAddress

Parameters

addressingVersion
AddressingVersion

The AddressingVersion of the current endpoint address.

reader
XmlDictionaryReader

The XmlDictionaryReader from which the endpoint address is obtained.

Returns

The EndpointAddress read from the XML dictionary reader.

Examples

XmlReader reader = XmlReader.Create("addressdata.xml");
XmlDictionaryReader dictReader = XmlDictionaryReader.CreateDictionaryReader(reader);
EndpointAddress createdEA = EndpointAddress.ReadFrom
                (AddressingVersion.WSAddressing10,
                 dictReader);

Applies to

ReadFrom(AddressingVersion, XmlReader)

Reads an endpoint address for a specified address version from a specified XML reader.

public:
 static System::ServiceModel::EndpointAddress ^ ReadFrom(System::ServiceModel::Channels::AddressingVersion ^ addressingVersion, System::Xml::XmlReader ^ reader);
public static System.ServiceModel.EndpointAddress ReadFrom (System.ServiceModel.Channels.AddressingVersion addressingVersion, System.Xml.XmlReader reader);
static member ReadFrom : System.ServiceModel.Channels.AddressingVersion * System.Xml.XmlReader -> System.ServiceModel.EndpointAddress
Public Shared Function ReadFrom (addressingVersion As AddressingVersion, reader As XmlReader) As EndpointAddress

Parameters

addressingVersion
AddressingVersion

The AddressingVersion of the current endpoint address.

reader
XmlReader

The XmlReader from which the endpoint address is obtained.

Returns

The EndpointAddress read from the XML reader.

Examples

The following code shows how to read in an endpoint address from an XML dictionary reader.

    XmlReader reader = XmlReader.Create("addressdata.xml");
    XmlDictionaryReader dictReader = XmlDictionaryReader.CreateDictionaryReader(reader);
    EndpointAddress createdEA = EndpointAddress.ReadFrom
(AddressingVersion.WSAddressing10,
 dictReader,
 "EndpointReference",
 "http://www.w3.org/2005/08/addressing");

Applies to

ReadFrom(XmlDictionaryReader, XmlDictionaryString, XmlDictionaryString)

Reads an endpoint address with a specified qualified name from a specified XML dictionary reader.

public:
 static System::ServiceModel::EndpointAddress ^ ReadFrom(System::Xml::XmlDictionaryReader ^ reader, System::Xml::XmlDictionaryString ^ localName, System::Xml::XmlDictionaryString ^ ns);
public static System.ServiceModel.EndpointAddress ReadFrom (System.Xml.XmlDictionaryReader reader, System.Xml.XmlDictionaryString localName, System.Xml.XmlDictionaryString ns);
static member ReadFrom : System.Xml.XmlDictionaryReader * System.Xml.XmlDictionaryString * System.Xml.XmlDictionaryString -> System.ServiceModel.EndpointAddress
Public Shared Function ReadFrom (reader As XmlDictionaryReader, localName As XmlDictionaryString, ns As XmlDictionaryString) As EndpointAddress

Parameters

reader
XmlDictionaryReader

The XmlDictionaryReader from which the endpoint address is obtained.

localName
XmlDictionaryString

An XmlDictionaryString that contains the local name for the XML node to contain the endpoint address.

ns
XmlDictionaryString

An XmlDictionaryString that contains the namespace for the XML node to contain the endpoint address.

Returns

The EndpointAddress with the qualified name read from the XML dictionary reader.

Examples

The following code shows how to read in an endpoint address from an XML dictionary reader.

XmlReader reader = XmlReader.Create("addressdata.xml");
XmlDictionaryReader dictReader = XmlDictionaryReader.CreateDictionaryReader(reader);
XmlDictionaryString xdLocalName = new XmlDictionaryString(XmlDictionary.Empty, "EndpointReference",0);
XmlDictionaryString xdNamespace = new XmlDictionaryString(XmlDictionary.Empty, "http://www.w3.org/2005/08/addressing", 0);
EndpointAddress createdEA = EndpointAddress.ReadFrom(dictReader, xdLocalName, xdNamespace);

Applies to

ReadFrom(AddressingVersion, XmlDictionaryReader, XmlDictionaryString, XmlDictionaryString)

Source:
EndpointAddress.cs
Source:
EndpointAddress.cs

Reads an endpoint address for a specified address version with a specified qualified name from a specified XML dictionary reader.

public:
 static System::ServiceModel::EndpointAddress ^ ReadFrom(System::ServiceModel::Channels::AddressingVersion ^ addressingVersion, System::Xml::XmlDictionaryReader ^ reader, System::Xml::XmlDictionaryString ^ localName, System::Xml::XmlDictionaryString ^ ns);
public static System.ServiceModel.EndpointAddress ReadFrom (System.ServiceModel.Channels.AddressingVersion addressingVersion, System.Xml.XmlDictionaryReader reader, System.Xml.XmlDictionaryString localName, System.Xml.XmlDictionaryString ns);
static member ReadFrom : System.ServiceModel.Channels.AddressingVersion * System.Xml.XmlDictionaryReader * System.Xml.XmlDictionaryString * System.Xml.XmlDictionaryString -> System.ServiceModel.EndpointAddress
Public Shared Function ReadFrom (addressingVersion As AddressingVersion, reader As XmlDictionaryReader, localName As XmlDictionaryString, ns As XmlDictionaryString) As EndpointAddress

Parameters

addressingVersion
AddressingVersion

The AddressingVersion of the current endpoint address.

reader
XmlDictionaryReader

The XmlDictionaryReader from which the endpoint address is obtained.

localName
XmlDictionaryString

Contains the local name for the XML node to contain the endpoint address.

ns
XmlDictionaryString

Contains the namespace for the XML node to contain the endpoint address.

Returns

The EndpointAddress with the qualified name read from the XML reader.

Examples

XmlReader reader = XmlReader.Create("addressdata.xml");
XmlDictionaryReader xReader = XmlDictionaryReader.CreateDictionaryReader(reader);
// Create an XmlDictionary and add values to it.
XmlDictionary d = new XmlDictionary();
XmlDictionaryString xdLocalName = new XmlDictionaryString(XmlDictionary.Empty, "EndpointReference",0);
XmlDictionaryString xdNamespace = new XmlDictionaryString(XmlDictionary.Empty, "http://www.w3.org/2005/08/addressing", 0);

EndpointAddress createdEA = EndpointAddress.ReadFrom
                (AddressingVersion.WSAddressing10,
                 xReader,
                 xdLocalName,
                 xdNamespace
                );

Applies to

ReadFrom(AddressingVersion, XmlReader, String, String)

Reads an endpoint address for a specified address version with a specified qualified name from a specified XML reader.

public:
 static System::ServiceModel::EndpointAddress ^ ReadFrom(System::ServiceModel::Channels::AddressingVersion ^ addressingVersion, System::Xml::XmlReader ^ reader, System::String ^ localName, System::String ^ ns);
public static System.ServiceModel.EndpointAddress ReadFrom (System.ServiceModel.Channels.AddressingVersion addressingVersion, System.Xml.XmlReader reader, string localName, string ns);
static member ReadFrom : System.ServiceModel.Channels.AddressingVersion * System.Xml.XmlReader * string * string -> System.ServiceModel.EndpointAddress
Public Shared Function ReadFrom (addressingVersion As AddressingVersion, reader As XmlReader, localName As String, ns As String) As EndpointAddress

Parameters

addressingVersion
AddressingVersion

The AddressingVersion of the current endpoint address.

reader
XmlReader

The XmlReader from which the endpoint address is obtained.

localName
String

Contains the local name for the XML node to contain the endpoint address.

ns
String

Contains the namespace for the XML node to contain the endpoint address.

Returns

The EndpointAddress with the qualified name read from the XML reader.

Examples

XmlReader reader = XmlReader.Create("addressdata.xml");
XmlDictionaryReader xReader = XmlDictionaryReader.CreateDictionaryReader(reader);
// Create an XmlDictionary and add values to it.
XmlDictionary d = new XmlDictionary();
XmlDictionaryString xdLocalName = new XmlDictionaryString(XmlDictionary.Empty, "EndpointReference",0);
XmlDictionaryString xdNamespace = new XmlDictionaryString(XmlDictionary.Empty, "http://www.w3.org/2005/08/addressing", 0);

EndpointAddress createdEA = EndpointAddress.ReadFrom
                (AddressingVersion.WSAddressing10,
                 xReader,
                 xdLocalName,
                 xdNamespace
                );

Applies to