2
使用HttpContext.Current.CurrentHandler進行運行時視圖訪問是否有任何潛在的缺陷?使用HttpContext.Current.CurrentHandler進行運行時視圖訪問
public static GetView<T>(T view) where T : IView
{
return HttpContext.Current.CurrentHandler as T;
}