4df4ba38a62b791bbbc25e923efe8d9c2f9a52e9 |
|
27-Jun-2015 |
Yigit Boyar <yboyar@google.com> |
Data binding startup improvement This CL replaces how we map tags(string) to layout ids in the generated DataBindingMapper class. Previously, we would create a hashmap which was some unnecessary work in startup. The alternative was using switch(string) but we did not want to require java 7. This CL does what java 7's switch(string) would do thanks to the well defined API of String.hashCode. This CL also adds a method to DataBindingUtil to convert BR.ids back to String for debugging purposes. Bug: 22108735 Change-Id: I4b8ef816f4aac99b2963793dd46519b056ce4a30
/frameworks/data-binding/integration-tests/TestApp/app/src/androidTestApi7/java/android/databinding/testapp/DataBindingMapperTest.java
|