Collection.shuffle not working - GWT

collections, java, shuffle

Solution

Quoted from GWT's JRE Emulation Reference:

Google Web Toolkit includes a library that emulates a subset of the Java runtime library. The list below shows the set of JRE packages, types and methods that GWT can translate automatically. Note that in some cases, only a subset of methods is supported for a given type.

Specifically, if you look at `Collections` in the Package java.util, you will see that it does not contain the `shuffle()` method.

Problem

Using the `import java.util.Collections;` like I should be. Not the GWT one. Have the class with the error in the shared folder for a GWT project. code is of this structure: ``` List<String []> qaList; qaList = new ArrayList<String[]>(); qaList.add("12345 main st", "tomah"); qaList.add("124 main st", "lacrosse"); qaList.add("123 main", "yeeehahaaa"); Collections.shuffle(qaList); ``` Gives me this error: [ERROR] [_012cfaexam] - Line 109: The method `shuffle(List<String[]>)` is undefined for the >type Collections

Original source