0

我有一个我创建的对象列表。我需要将它传递给另一个活动。它不工作

List<Dog> myDogs = ...
intent.putExtra(ALL_MY_DOGS,myDogs);

我得到编译错误:

The method putExtra(String, boolean) in the type Intent is not applicable for the
arguments (String, List<Dog>)
4

1 回答 1

0

我发现了错误。我传递的是一个列表而不是一个 ArrayList。

于 2013-08-28T21:18:30.943 回答