I have the following question:
if I have the following line of code:
List<Position> allPos = posDBM.getAllPos();
Position
is an object
posDBM
is a SQLite Database Manager class, which manages the SQLite database,
getAllPos()
returns all database data.
The return type of getAllPos()
is List<Position>
.
If I want to initialize a List<>
like this List<Position> pos = new
, I have to specify the type of the List
(ArrayList, LinkedList, etc.) .
So back to my question, what kind of List do I have, after I filled the list from the database?
I would guess it's an ArrayList
, but I can't find any source to back this up. It's just a matter of interest...