Convert ArrayList to java.util.List [closed]

I don’t understand the problem you have since an ArrayList implements a List with List being an interface.

You can change this line

ArrayList<String> orderNumbers = new ArrayList<String>(); 

to:

List<String> orderNumbers = new ArrayList<String>();

Leave a Comment