IViewEngine.GetView(String, String, Boolean) 方法

定义

获取具有给定 viewPath的视图,相对于 executingFilePath (除非 viewPath 已为绝对值)。

public:
 Microsoft::AspNetCore::Mvc::ViewEngines::ViewEngineResult ^ GetView(System::String ^ executingFilePath, System::String ^ viewPath, bool isMainPage);
public Microsoft.AspNetCore.Mvc.ViewEngines.ViewEngineResult GetView (string executingFilePath, string viewPath, bool isMainPage);
public Microsoft.AspNetCore.Mvc.ViewEngines.ViewEngineResult GetView (string? executingFilePath, string viewPath, bool isMainPage);
abstract member GetView : string * string * bool -> Microsoft.AspNetCore.Mvc.ViewEngines.ViewEngineResult
Public Function GetView (executingFilePath As String, viewPath As String, isMainPage As Boolean) As ViewEngineResult

参数

executingFilePath
String

当前正在执行的视图的绝对路径(如果有)。

viewPath
String

视图的路径。

isMainPage
Boolean

确定找到的页面是否是操作main页。

返回

查找 ViewEngineResult 视图的 。

适用于