KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
When I have an interface public interface Foo<T> { T someMethod(); } is there any way to assure that when some class implements this interface then generic type is the same implementig class. For example: public class Bar implements Foo<Bar> { Bar someMethod() { return new Bar(); } }
Tags (comma-separated)
Save Edits
Cancel