How/Where Can I find the generated code for ViewBinding?
whenever I try control+click/control+b to see the declaration, AndroidStudio just opens the XML layout.
How/Where Can I find the generated code for ViewBinding?
whenever I try control+click/control+b to see the declaration, AndroidStudio just opens the XML layout.
The generate binding classes reside in app > build > generated > data_binding_base_class_source_out > debug > your app package > databinding
A you can see in the following screenshot all my ViewBinding classes for XML layout are inside the above path
You can use the Ctrl + Shift + N
(Go to file) to find the file with BindingImpl
suffix.
The name of the generated class for your_layout.xml is YourLayoutBindingImpl.java. so you can find the implementation using double-shift.
The name of the generated class for my_layout.xml
is MyLayoutBinding.java
. so you can find the implementation in MyProject/app/build/intermediates/javac/googleDebugStage/classes/you_package/databinding
© 2022 - 2024 — McMap. All rights reserved.