1
我在寫我自己的視圖引擎。在ViewEngine中獲取屬性值ASP.NET MVC 3
public class MyViewEngine : RazorViewEngine
{
public override ViewEngineResult FindView(ControllerContext controllerContext, string viewName, string masterName, bool useCache)
{
// Here, how do I get attributes defined on top of the Action ?
}
}
ASP.NET MVC Custom Attributes within Custom View Engine
上方,問題有如何獲得在控制器上面定義的屬性。但我需要獲取Action上定義的屬性。