Class ContentUrlGeneratorExtensions
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Extension methods for IContent
Inheritance
Inherited Members
Namespace: EPiServer.Core.Routing.Internal
Assembly: EPiServer.dll
Version: 11.20.7Syntax
public static class ContentUrlGeneratorExtensions
Methods
Generate(IContentUrlGenerator, ContentReference)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Generates an url for a content instance.
Declaration
public static Uri Generate(this IContentUrlGenerator generateUrl, ContentReference contentLink)
Parameters
Type | Name | Description |
---|---|---|
IContent |
generateUrl | The url generator that is extended |
Content |
contentLink | A reference for the content for which the url is to be generated |
Returns
Type | Description |
---|---|
System. |
The generated url or null if no url could be generated |
Remarks
Language will be determined from request context.
Generate(IContentUrlGenerator, ContentReference, CultureInfo)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Generates an url for a content instance in the specified language
Declaration
public static Uri Generate(this IContentUrlGenerator generateUrl, ContentReference contentLink, CultureInfo language)
Parameters
Type | Name | Description |
---|---|---|
IContent |
generateUrl | The url generator that is extended |
Content |
contentLink | A reference for the content for which the url is to be generated |
System. |
language | The language version to generate an url for |
Returns
Type | Description |
---|---|
System. |
The generated url or null if no url could be generated |