本文介绍了如何继承通用基类窗口的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

那么,WPF在XAML中添加了对泛型的新支持?但它似乎仍然缺少一些基本的支持,或者我如何解决这个问题:

我希望有一个通用的基类,我的所有窗口都继承了它。该类看起来像这样:



  public   abstract   class  CoreBaseWindow< TCollection,TEntity> :窗口

解决方案

So, WPF has added new support for generics in XAML? But it still seems to miss some fundamental support, or how do I solve this:

I want to have a generic base class that all my windows inherit from. The class looks like this:

public abstract class CoreBaseWindow<TCollection, TEntity> : Window

解决方案


这篇关于如何继承通用基类窗口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-14 04:39