java.lang.ClassCastException: java.util.Arrays$ArrayList cannot be cast to java.util.ArrayList

前端 未结 3 1829
时光说笑
时光说笑 2020-12-08 18:23

Can you explain me why does this happen and how can I fix it please?

So I\'m using Oracle-ADF and I\'m using shuttle components. I get the selected values using the

3条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-08 18:56

    The ArrayList returned by Arrays.asList() method is NOT java.util.ArrayList it is a static inner class inside Arrays class. So, you can't cast it to java.util.ArrayList.

    Try converting / assigning it to a List.

提交回复
热议问题