Interface ISiteDomainMapper
Provides utilities to handle site domains.
Namespace: Umbraco.Cms.Core.Routing
Assembly: Umbraco.Core.dll
Syntax
public interface ISiteDomainMapper
Methods
View SourceMapDomain(IReadOnlyCollection<DomainAndUri>, Uri, String, String)
Filters a list of DomainAndUri to pick one that best matches the current request.
Declaration
DomainAndUri MapDomain(IReadOnlyCollection<DomainAndUri> domainAndUris, Uri current, string culture, string defaultCulture)
Parameters
| Type | Name | Description |
|---|---|---|
| IReadOnlyCollection<DomainAndUri> | domainAndUris | The list of |
| Uri | current | The Uri of the current request. |
| System.String | culture | A culture. |
| System.String | defaultCulture | The default culture. |
Returns
| Type | Description |
|---|---|
| DomainAndUri | The selected |
Remarks
If the filter is invoked then domainAndUris is not empty and
current is not null, and current could not be
matched with anything in domainAndUris.
The culture may be null, but when non-null, it can be used
to help pick the best matches.
The filter must return something else an exception will be thrown.
MapDomains(IReadOnlyCollection<DomainAndUri>, Uri, Boolean, String, String)
Filters a list of DomainAndUri to pick those that best matches the current request.
Declaration
IEnumerable<DomainAndUri> MapDomains(IReadOnlyCollection<DomainAndUri> domainAndUris, Uri current, bool excludeDefault, string culture, string defaultCulture)
Parameters
| Type | Name | Description |
|---|---|---|
| IReadOnlyCollection<DomainAndUri> | domainAndUris | The list of |
| Uri | current | The Uri of the current request. |
| System.Boolean | excludeDefault | A value indicating whether to exclude the current/default domain. |
| System.String | culture | A culture. |
| System.String | defaultCulture | The default culture. |
Returns
| Type | Description |
|---|---|
| IEnumerable<DomainAndUri> | The selected |
Remarks
The filter must return something, even empty, else an exception will be thrown.
The culture may be null, but when non-null, it can be used
to help pick the best matches.