ViewResult Třída

Definice

Představuje ActionResult objekt , který vykreslí zobrazení odpovědi.

public ref class ViewResult : Microsoft::AspNetCore::Mvc::ActionResult
public ref class ViewResult : Microsoft::AspNetCore::Mvc::ActionResult, Microsoft::AspNetCore::Mvc::IActionResult, Microsoft::AspNetCore::Mvc::Infrastructure::IStatusCodeActionResult
public class ViewResult : Microsoft.AspNetCore.Mvc.ActionResult
public class ViewResult : Microsoft.AspNetCore.Mvc.ActionResult, Microsoft.AspNetCore.Mvc.IActionResult, Microsoft.AspNetCore.Mvc.Infrastructure.IStatusCodeActionResult
type ViewResult = class
    inherit ActionResult
type ViewResult = class
    inherit ActionResult
    interface IStatusCodeActionResult
    interface IActionResult
type ViewResult = class
    inherit ActionResult
    interface IActionResult
    interface IStatusCodeActionResult
Public Class ViewResult
Inherits ActionResult
Public Class ViewResult
Inherits ActionResult
Implements IActionResult, IStatusCodeActionResult
Dědičnost
ViewResult
Implementuje

Konstruktory

ViewResult()

Vlastnosti

ContentType

Získá nebo nastaví hlavičku Content-Type odpovědi.

Model

Získá datový model zobrazení.

StatusCode

Získá nebo nastaví stavový kód HTTP.

TempData

Získá nebo nastaví ITempDataDictionary pro tento výsledek.

ViewData

Získá nebo nastaví ViewDataDictionary pro tento výsledek.

ViewEngine

Získá nebo nastaví IViewEngine vlastnost použitou k vyhledání zobrazení.

ViewName

Získá nebo nastaví název nebo cestu zobrazení, které se vykreslí do odpovědi.

Metody

ExecuteResult(ActionContext)

Provede operaci výsledku metody akce synchronně. MVC volá tuto metodu, aby zpracuje výsledek metody akce.

(Zděděno od ActionResult)
ExecuteResultAsync(ActionContext)

Spustí operaci výsledku metody akce asynchronně. Tato metoda je volána MVC ke zpracování výsledku metody akce.

Platí pro