For subclasses that inherit the parent class, the parent class then inherits the BaseActivity. If the BaseActivity uses the inject() method, you need to write
@Autowired open lateinit var hardware: HardWare
Write in subclass:
@Autowired override lateinit var hardware: HardWare
In this way, the problem of Arouter inject error will not be caused
Read More:
- [Solved] ARouter Error: There is no route matched
- Android 10: How to Solve Systemui Error
- How to Solve Error inflating class android.support.design.widget.FloatingActionButton
- How to Solve Android Error: gps requires ACCESS_FINE_LOCATION
- How to Solve Android jetpack Room Schema export Error
- How to Solve Error: Android java.lang.IllegalStateException: Could not execute method of the activity
- Android: How to Solve libuv Compile Error
- How to Solve Android Studio run main() Method Error
- Android Studio: How to Solve APK error in mobile phone installation
- How to Solve Error “Could not find com.android.tools.build:gradle:3.0.1”
- How to Solve Android wechat payment Error: error_code = -1
- How to Solve Android Error: Error inflating class
- JZVideo Error: Attempt to invoke virtual method ‘android.view.Window android.app.Activity.getWindow()’ on a null object reference
- How to Solve Error: You need to use a Theme.AppCompat theme (or descendant) with this activity.
- How to Solve Namedparameterjdbctemplate.queryforobject() Return Error
- How to Solve Error: Type mismatch: cannot convert from Object to Car
- How to Solve using stm32f4 to drive PS2 error
- How to Solve Spring Cloud Error context has been closed already
- Kotlin: How to Solve kapt import error
- How to Solve SpringBoot MongoDB MongoAutoConfiguration Startup Error