New course! Every coder should learn Generative AI!
Try a free lesson+ 1
return type can be Generic?
as I know a method can't return generic type except whenever it accepts a generic type as argument. so how developers have defined "T findViewById(int)"? is it defined in native code?
2 Answers
0
see developer.android.com.
<T extends View> findViewById
0
Maybe findViewById returns a type View. Which is not a generic type.
View findViewById(int)