I am developing Interface for a sample project i wanted it to be as generic as possible so i created a interface like below
public interface IUserFactory
{
IEnumerable<Users> GetAll();
Users GetOne(int Id);
}
but then it happened i had to duplicate the interface to do below
public interface IProjectFactory
{
IEnumerable<Projects> GetAll(User user);
Project GetOne(int Id);
}
if you looked at above difference is just types they return, so i created something like below only to find i get error Cannot Resolve Symbol T
What am i doing wrong
public interface IFactory
{
IEnumerable<T> GetAll();
T GetOne(int Id);
}