SyndicationLink.CreateAlternateLink SyndicationLink.CreateAlternateLink SyndicationLink.CreateAlternateLink Method

Definition

Creates a new SyndicationLink object.

Overloads

CreateAlternateLink(Uri) CreateAlternateLink(Uri) CreateAlternateLink(Uri)

Creates a new SyndicationLink object with the specified Uri.

CreateAlternateLink(Uri, String) CreateAlternateLink(Uri, String) CreateAlternateLink(Uri, String)

Creates a new SyndicationLink object with the specified Uri and media type.

Remarks

This method creates a new SyndicationLink object and sets RelationshipType to alternate.

Creates a new SyndicationLink object with the specified Uri.

public:
 static System::ServiceModel::Syndication::SyndicationLink ^ CreateAlternateLink(Uri ^ uri);
public static System.ServiceModel.Syndication.SyndicationLink CreateAlternateLink (Uri uri);
static member CreateAlternateLink : Uri -> System.ServiceModel.Syndication.SyndicationLink

Parameters

uri
Uri Uri Uri

The URI of the linked resource.

Returns

Examples

The following example shows how to create an alternate link.

SyndicationLink link = SyndicationLink.CreateAlternateLink(new Uri("http://server/link"));
Dim link As SyndicationLink = SyndicationLink.CreateAlternateLink(New Uri("http://server/link"))

Creates a new SyndicationLink object with the specified Uri and media type.

public:
 static System::ServiceModel::Syndication::SyndicationLink ^ CreateAlternateLink(Uri ^ uri, System::String ^ mediaType);
public static System.ServiceModel.Syndication.SyndicationLink CreateAlternateLink (Uri uri, string mediaType);
static member CreateAlternateLink : Uri * string -> System.ServiceModel.Syndication.SyndicationLink

Parameters

uri
Uri Uri Uri

The URI of the linked resource.

mediaType
String String String

The media type of the link.

Returns

Examples

The following example shows how to create an alternate link.

SyndicationLink link = SyndicationLink.CreateAlternateLink(new Uri("http://server/link"), "text/html");
Dim link As SyndicationLink = SyndicationLink.CreateAlternateLink(New Uri("http://server/link"), "text/html")

Applies to