I want to export a generic class to a generic interface via MEF. My objects are:
public interface IService<T> { }
[Export(typeof(IService<T>))] // error!!!!!!
public class Service<T> { }
public class Client<T> {
[Import]
private IService<T> _service;
}
But when I try to export IService<T>
, I get this error:
Attribute argument cannot use type parameters
Can anybody guide me to do this please?