SyndicationLink.CreateSelfLink SyndicationLink.CreateSelfLink SyndicationLink.CreateSelfLink Method

Definition

Creates a new SyndicationLink with the relationship type set to self.

Overloads

CreateSelfLink(Uri, String) CreateSelfLink(Uri, String) CreateSelfLink(Uri, String)

Creates a new SyndicationLink with the specified URI, media type, and relationship type set to self.

CreateSelfLink(Uri) CreateSelfLink(Uri) CreateSelfLink(Uri)

Creates a new SyndicationLink with the specified URI and relationship type set to self.

Remarks

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

Creates a new SyndicationLink with the specified URI, media type, and relationship type set to self.

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

Parameters

uri
Uri Uri Uri

The URI to the linked resource.

mediaType
String String String

The media type of the link.

Returns

Examples

The following example shows how to create a self link.

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

Creates a new SyndicationLink with the specified URI and relationship type set to self.

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

Parameters

uri
Uri Uri Uri

The URI to the linked resource.

Returns

Examples

The following example shows how to create a self link.

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

Applies to