Source does not fit in dest 异常

. Source does not fit in dest

事由:   Collections.copy(products, orderProductList);
 
原因: dest products 的size 为0
 
解决:  List<Object> products = new  ArrayList<Object (Arrays.asList( new  Object[orderProductList .size()]));

你可能感兴趣的:(source)