you could do that with a repository strategy. a generic way is difficult as you would need to know which field is the "title"