PeerContact.FromXml Method (String)


Creates a PeerContact instance based on provided XML data.

Namespace:   System.Net.PeerToPeer.Collaboration
Assembly:  System.Net (in System.Net.dll)

public static PeerContact FromXml(
	string peerContactXml


Type: System.String

The XML encoding used to reconstruct the PeerContact.

Return Value

Type: System.Net.PeerToPeer.Collaboration.PeerContact

A string that represents the XML object model for encoding the PeerContact instance.

Exception Condition

Parameter cannot be null.

  • Unable to complete FromXml operation

  • Parameter is not a valid FromXml object.

The string to pass as the parameter should be obtained from ToXml.

This class is intended to be a lightweight implementation of a simple XML object model for use within the collaboration infrastructure, and not for use as a general XML object model.

.NET Framework
Available since 3.5
Return to top