2
I’m trying to use a List
of List
s in Java in Netbeans for the first time:
List<List<String>> listao = new ArrayList<>();
But it presents a compilation error on the line where I have the list:
error: Diamond Operator is not supported in -source 1.5
And present the hint:
use -source 7 or Higher to enable Diamond Operator
Okay, but what source is this, and how to do this?
The tip is clear, Voce need to use a version of jdk 7 or higher to use diamond operator. Its version is 1.5 does not support.
– user28595
Related: Arraylist statement with type or without
– user28595