xamarin.android - Xamarin.Android binding generation giving "Type X was not found" errors for classes new in JDK 1.8
问题描述
I'm trying to get Xamarin.Android to generate bindings for a library supplied as an AAR. JAR2XML is giving me a lot of "can't find type" errors, so I thought I'd try class-parse, but in addition to some library references I'm trying to track down, I'm getting a couple of these:
1> Error while processing '[Method] java.time.temporal.Temporal adjustInto(java.time.temporal.Temporal temporal, long newValue)' in '[Class] java.time.temporal.ChronoField': Type 'java.time.temporal.Temporal' was not found. (TaskId:69)
1> Error while processing '[Method] java.time.temporal.Temporal addTo(java.time.temporal.Temporal temporal, long amount)' in '[Class] java.time.temporal.ChronoUnit': Type 'java.time.temporal.Temporal' was not found. (TaskId:69)
Now, java.time.temporal.Temporal
is a new type in JDK 1.8, so I'm wondering if maybe that's part of my problem here (ie. maybe the types that can't load are using other new-in-1.8 types). Running bin\javac -version
in the path specified in Options-Xamarin-Android Settings says I'm using "1.8.0_172". My project is targeting "Android 8.1 (Oreo)" - ie. api level 27. Is there some other option I need to set to make sure I'm using 1.8?
解决方案
推荐阅读
- android - Android RecyclerView 中的 Glide 缓存不起作用
- java - Spring Data Rest 存储库偶尔不会导出
- python - BeautifulSoup 抓取位于 csv 中的 URL,然后输出到新的 csv
- c - 为什么 scanf 不读取零
- json - 在flutter的下拉框中填充json api数据
- tcl - 关闭 TCL 中的应用程序/窗口
- r - R循环名称和变量
- excel - 当我完成一行的输入时,如何制作一个 OnEdit() 脚本,按 3 列对我的数据进行重新排序?
- python - 如何在 python 3 中运行 shellcode?
- node.js - 如何使用 React Native 将用户的输入导出到 Excel 中