SyndicationLink.CreateAlternateLink Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a new SyndicationLink object.
Overloads
CreateAlternateLink(Uri) |
Creates a new SyndicationLink object with the specified Uri. |
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
.
CreateAlternateLink(Uri)
- Source:
- SyndicationLink.cs
- Source:
- SyndicationLink.cs
- Source:
- SyndicationLink.cs
- Source:
- SyndicationLink.cs
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
Public Shared Function CreateAlternateLink (uri As Uri) As SyndicationLink
Parameters
- uri
- Uri
The URI of the linked resource.
Returns
A new SyndicationLink instance.
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"))
Applies to
CreateAlternateLink(Uri, String)
- Source:
- SyndicationLink.cs
- Source:
- SyndicationLink.cs
- Source:
- SyndicationLink.cs
- Source:
- SyndicationLink.cs
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
Public Shared Function CreateAlternateLink (uri As Uri, mediaType As String) As SyndicationLink
Parameters
- uri
- Uri
The URI of the linked resource.
- mediaType
- String
The media type of the link.
Returns
A new SyndicationLink instance.
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
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應