While using data binding , I am not able to get class MainActivityBinding as per Data Binding Guide
My layout name is activity_main.xml.
I
In my case DELETING the the app build folder and then rebuilding the project solved my problem.
Even following steps did not work.
1) Rebuild the project after adding the dataBinding in gradle.
2) Rebuild after adding layout tag in xml.
3) cleaning the project
4) rebuilding the project
5) Restarted the Android Studio
After enabling the dataBinding in app gradle file please rebuild. Then we can find Binding class generated.
If the layout name is fragment_home, The Binding class name will be FragmentHomeBinding.