Class UrlResolverOptionsExtensions
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Extension methods for UrlResolverOptions
Inheritance
Inherited Members
Namespace: EPiServer.Core.Routing.Internal
Assembly: EPiServer.dll
Version: 10.10.4Syntax
public static class UrlResolverOptionsExtensions
Methods
GetDefaultHost(UrlResolverOptions)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Gets the host option that will be used as default for relative URL's
Declaration
public static HostDefinition GetDefaultHost(this UrlResolverOptions options)
Parameters
Type | Name | Description |
---|---|---|
UrlResolverOptions | options | The options container that is extended |
Returns
Type | Description |
---|---|
HostDefinition | The host option or null if it does not exist |
GetFallbackToWildcardHost(UrlResolverOptions)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Gets an option if wildcard host should be used as fallback after trying to find a matching host and site
Declaration
public static bool GetFallbackToWildcardHost(this UrlResolverOptions options)
Parameters
Type | Name | Description |
---|---|---|
UrlResolverOptions | options | The options container that is extended |
Returns
Type | Description |
---|---|
System.Boolean | The wildcard host option or |
SetDefaultHost(UrlResolverOptions, HostDefinition)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Sets a host option that will be used as default for relative URL's
Declaration
public static UrlResolverOptions SetDefaultHost(this UrlResolverOptions options, HostDefinition host)
Parameters
Type | Name | Description |
---|---|---|
UrlResolverOptions | options | The options container that is extended |
HostDefinition | host | The host to set |
Returns
Type | Description |
---|---|
UrlResolverOptions | The options container |
Remarks
The resolver defaults to the current HTTP request if no default host is specified
SetFallbackToWildcardHost(UrlResolverOptions, Boolean)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Sets an option if wildcard host should be used as fallback after trying to find a matching host and site
Declaration
public static UrlResolverOptions SetFallbackToWildcardHost(this UrlResolverOptions options, bool fallbackToWildcard = true)
Parameters
Type | Name | Description |
---|---|---|
UrlResolverOptions | options | The options container that is extended |
System.Boolean | fallbackToWildcard | The wildcard option to set |
Returns
Type | Description |
---|---|
UrlResolverOptions | The options container |
Remarks
If no wilcard host exists this setting has no effect on the URL resolver