草庐IT

SchematicContentProvider

全部标签

Android原理图内容提供者库配置?

JakeWharton在最近的一次演讲中提到了这个库,它看起来是避免大量样板文件的好方法,所以我试了一下。但没有任何成功。https://github.com/SimonVT/schematic下面是带有注释的内容提供者的定义和list提供者元素。问题是AndroidStudio不喜欢提供者定义,因为内容提供者类没有扩展ContentProvider。Causedby:java.lang.ClassCastException:com.myapp.SchematicContentProvidercannotbecasttoandroid.content.ContentProvider我错