combining inheritance of generic types and constraints:
using System;
using System.Collections;
public class MyClass<T> where T : IComparable {
}
public class YClass<T> : MyClass<T> where T : IComparable {
}
public class XClass<T> : MyClass<T> where T : IComparable, IDisposable {
}
public class BClass<Y> where Y : IEnumerable {
}
public class AClass<Z> : BClass<int[]> where Z : IDisposable {
}
Related examples in the same category