class MyCollection : CollectionBase, IMyCollection
{
#region IMyCollection Members
int IMyCollection.Count
{
get
{
throw new NotImplementedException();
}
set
{ throw new NotImplementedException(); } }
}
#endregion
}
internal interface IMyCollection
{
int Count
{
get;set;
}
}
class MyCollection
{
public void GenericMethod<T>(T param) where T:MyCollection
{
Debug.Write(param.Count);
}
}