Caused by: java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType at de.trbnb.mvvmbase.MvvmBindingActivity.getViewModelClass(MvvmBindingActivity.kt:87) at de.trbnb.mvvmbase.MvvmBindingActivity.onCreate(MvvmBindingActivity.kt:119) at de.intech.main.gui.overview.OverviewActivity.onCreate(OverviewActivity.kt:52)
OverviewActivity is an abstract activity class. Got two activity classes inheriting from this overview activity class. They both use the same ViewModel class that is provided inside the OverviewActivity. The shared ViewModel class has one constructor parameter. But removing this, was not preventing the error.
Got the following crash:
Caused by: java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType at de.trbnb.mvvmbase.MvvmBindingActivity.getViewModelClass(MvvmBindingActivity.kt:87) at de.trbnb.mvvmbase.MvvmBindingActivity.onCreate(MvvmBindingActivity.kt:119) at de.intech.main.gui.overview.OverviewActivity.onCreate(OverviewActivity.kt:52)
OverviewActivity is an abstract activity class. Got two activity classes inheriting from this overview activity class. They both use the same ViewModel class that is provided inside the OverviewActivity. The shared ViewModel class has one constructor parameter. But removing this, was not preventing the error.