Java type casting generics list of list of child to list of list of parent -


this question has answer here:

i have class childdata1 extends data. how can convert list<list<childdata1>> list<list<data>> ?

under rules of generics can following assignment without cast:

list<list<childdata>> subclasslist = ... list<? extends list<? extends data>> superclasslist = subclasslist; 

Comments

Popular posts from this blog

user interface - How to replace the Python logo in a Tkinter-based Python GUI app? -

objective c - Greedy NSProgressIndicator Allocation -

how to set an OCR language in Google Drive -