aidl 使用中,有时候我们需要传递List数据,根据谷歌爸爸的文档,是支持的,但是我代码中写入如下的内容,一值报错
interface IPrintAidlInterface {
/**
* Demonstrates some basic types that you can use as parameters
* and return values in AIDL.
*/
void print(String textContent, List<Bitmap> portrait, String bitmapAdditionalContent);
void onPause();
void onResume();
}
后来去谷歌爸爸的文档上看,谷歌爸爸的文档上面只说了支持List 类型,但是没有在Demo中演示怎么用.
后来在这篇博客上找到了,参考
要在List前面加上in 就可以了编译通过了.