Class ApiMediaUrlProvider
Default implementation of IApiMediaUrlProvider that provides media URLs for the Delivery API.
Inheritance
object
Namespace: Umbraco.Cms.Core.DeliveryApi
Assembly: Umbraco.Core.dll
Syntax
public sealed class ApiMediaUrlProvider : IApiMediaUrlProvider
Constructors
View SourceApiMediaUrlProvider(IPublishedUrlProvider)
Initializes a new instance of the ApiMediaUrlProvider class.
Declaration
public ApiMediaUrlProvider(IPublishedUrlProvider publishedUrlProvider)
Parameters
| Type | Name | Description |
|---|---|---|
| IPublishedUrlProvider | publishedUrlProvider | The published URL provider. |
Methods
View SourceGetUrl(IPublishedContent)
Gets the URL for the specified media item.
Declaration
public string GetUrl(IPublishedContent media)
Parameters
| Type | Name | Description |
|---|---|---|
| IPublishedContent | media | The published media to get the URL for. |
Returns
| Type | Description |
|---|---|
| string | The URL of the media item. |