MvcLocalizationMvcBuilderExtensions.AddViewLocalization 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.
Overloads
AddViewLocalization(IMvcBuilder) |
Adds MVC view localization services to the application. |
AddViewLocalization(IMvcBuilder, LanguageViewLocationExpanderFormat) |
Adds MVC view localization services to the application. |
AddViewLocalization(IMvcBuilder, Action<LocalizationOptions>) |
Adds MVC view localization services to the application. |
AddViewLocalization(IMvcBuilder, LanguageViewLocationExpanderFormat, Action<LocalizationOptions>) |
Adds MVC view localization services to the application. |
AddViewLocalization(IMvcBuilder)
Adds MVC view localization services to the application.
public static Microsoft.Extensions.DependencyInjection.IMvcBuilder AddViewLocalization (this Microsoft.Extensions.DependencyInjection.IMvcBuilder builder);
static member AddViewLocalization : Microsoft.Extensions.DependencyInjection.IMvcBuilder -> Microsoft.Extensions.DependencyInjection.IMvcBuilder
<Extension()>
Public Function AddViewLocalization (builder As IMvcBuilder) As IMvcBuilder
Parameters
- builder
- IMvcBuilder
The IMvcBuilder.
Returns
The IMvcBuilder.
Applies to
AddViewLocalization(IMvcBuilder, LanguageViewLocationExpanderFormat)
Adds MVC view localization services to the application.
public static Microsoft.Extensions.DependencyInjection.IMvcBuilder AddViewLocalization (this Microsoft.Extensions.DependencyInjection.IMvcBuilder builder, Microsoft.AspNetCore.Mvc.Razor.LanguageViewLocationExpanderFormat format);
static member AddViewLocalization : Microsoft.Extensions.DependencyInjection.IMvcBuilder * Microsoft.AspNetCore.Mvc.Razor.LanguageViewLocationExpanderFormat -> Microsoft.Extensions.DependencyInjection.IMvcBuilder
<Extension()>
Public Function AddViewLocalization (builder As IMvcBuilder, format As LanguageViewLocationExpanderFormat) As IMvcBuilder
Parameters
- builder
- IMvcBuilder
The IMvcBuilder.
The view format for localized views.
Returns
The IMvcBuilder.
Applies to
AddViewLocalization(IMvcBuilder, Action<LocalizationOptions>)
Adds MVC view localization services to the application.
public static Microsoft.Extensions.DependencyInjection.IMvcBuilder AddViewLocalization (this Microsoft.Extensions.DependencyInjection.IMvcBuilder builder, Action<Microsoft.Extensions.Localization.LocalizationOptions> setupAction);
public static Microsoft.Extensions.DependencyInjection.IMvcBuilder AddViewLocalization (this Microsoft.Extensions.DependencyInjection.IMvcBuilder builder, Action<Microsoft.Extensions.Localization.LocalizationOptions>? setupAction);
static member AddViewLocalization : Microsoft.Extensions.DependencyInjection.IMvcBuilder * Action<Microsoft.Extensions.Localization.LocalizationOptions> -> Microsoft.Extensions.DependencyInjection.IMvcBuilder
<Extension()>
Public Function AddViewLocalization (builder As IMvcBuilder, setupAction As Action(Of LocalizationOptions)) As IMvcBuilder
Parameters
- builder
- IMvcBuilder
The IMvcBuilder.
- setupAction
- Action<LocalizationOptions>
An action to configure the LocalizationOptions.
Returns
The IMvcBuilder.
Applies to
AddViewLocalization(IMvcBuilder, LanguageViewLocationExpanderFormat, Action<LocalizationOptions>)
Adds MVC view localization services to the application.
public static Microsoft.Extensions.DependencyInjection.IMvcBuilder AddViewLocalization (this Microsoft.Extensions.DependencyInjection.IMvcBuilder builder, Microsoft.AspNetCore.Mvc.Razor.LanguageViewLocationExpanderFormat format, Action<Microsoft.Extensions.Localization.LocalizationOptions> setupAction);
public static Microsoft.Extensions.DependencyInjection.IMvcBuilder AddViewLocalization (this Microsoft.Extensions.DependencyInjection.IMvcBuilder builder, Microsoft.AspNetCore.Mvc.Razor.LanguageViewLocationExpanderFormat format, Action<Microsoft.Extensions.Localization.LocalizationOptions>? setupAction);
static member AddViewLocalization : Microsoft.Extensions.DependencyInjection.IMvcBuilder * Microsoft.AspNetCore.Mvc.Razor.LanguageViewLocationExpanderFormat * Action<Microsoft.Extensions.Localization.LocalizationOptions> -> Microsoft.Extensions.DependencyInjection.IMvcBuilder
<Extension()>
Public Function AddViewLocalization (builder As IMvcBuilder, format As LanguageViewLocationExpanderFormat, setupAction As Action(Of LocalizationOptions)) As IMvcBuilder
Parameters
- builder
- IMvcBuilder
The IMvcBuilder.
The view format for localized views.
- setupAction
- Action<LocalizationOptions>
An action to configure the LocalizationOptions.
Returns
The IMvcBuilder.