ViewComponent ViewComponent ViewComponent ViewComponent ViewComponent ViewComponent Class

Definition

A base class for view components.

public ref class ViewComponent abstract
[Windows::Foundation::Metadata::WebHostHidden]
public ref class ViewComponent abstract
[Windows::Foundation::Metadata::WebHostHidden]
class ViewComponent abstract
[Microsoft.AspNetCore.Mvc.ViewComponent]
public abstract class ViewComponent
type ViewComponent = class
Public MustInherit Class ViewComponent
Inheritance
ViewComponentViewComponentViewComponentViewComponentViewComponentViewComponent
Attributes

Constructors

ViewComponent() ViewComponent() ViewComponent() ViewComponent() ViewComponent() ViewComponent()

Properties

HttpContext HttpContext HttpContext HttpContext HttpContext HttpContext

Gets the HttpContext.

ModelState ModelState ModelState ModelState ModelState ModelState

Gets the ModelStateDictionary.

Request Request Request Request Request Request

Gets the HttpRequest.

RouteData RouteData RouteData RouteData RouteData RouteData

Gets the RouteData for the current request.

TempData TempData TempData TempData TempData TempData

Gets the ITempDataDictionary.

Url Url Url Url Url Url

Gets or sets the IUrlHelper.

User User User User User User

Gets the IPrincipal for the current user.

UserClaimsPrincipal UserClaimsPrincipal UserClaimsPrincipal UserClaimsPrincipal UserClaimsPrincipal UserClaimsPrincipal

Gets the ClaimsPrincipal for the current user.

ViewBag ViewBag ViewBag ViewBag ViewBag ViewBag

Gets the view bag.

ViewComponentContext ViewComponentContext ViewComponentContext ViewComponentContext ViewComponentContext ViewComponentContext
ViewContext ViewContext ViewContext ViewContext ViewContext ViewContext

Gets the ViewContext.

ViewData ViewData ViewData ViewData ViewData ViewData

Gets the ViewDataDictionary.

ViewEngine ViewEngine ViewEngine ViewEngine ViewEngine ViewEngine

Gets or sets the ICompositeViewEngine.

Methods

Content(String) Content(String) Content(String) Content(String) Content(String) Content(String)

Returns a result which will render HTML encoded text.

View() View() View() View() View() View()

Returns a result which will render the partial view with name "Default".

View(String) View(String) View(String) View(String) View(String) View(String)

Returns a result which will render the partial view with name viewName.

View<TModel>(TModel) View<TModel>(TModel) View<TModel>(TModel) View<TModel>(TModel) View<TModel>(TModel) View<TModel>(TModel)

Returns a result which will render the partial view with name "Default".

View<TModel>(String, TModel) View<TModel>(String, TModel) View<TModel>(String, TModel) View<TModel>(String, TModel) View<TModel>(String, TModel) View<TModel>(String, TModel)

Returns a result which will render the partial view with name viewName.

Applies to