You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I realize this is a bit counter intuitive to the intent of the library, but I ran into the following exception when I had no bindings defined in my Item view model:
java.lang.IllegalStateException: Could not bind variable '3' in layout '<...>/item'
at me.tatarka.bindingcollectionadapter.BindingCollectionAdapters.throwMissingVariable(BindingCollectionAdapters.java:276)
I ran into the exception while stubbing classes and layouts out to test the library. When I added a binding in my layout, everything worked fine. It seems like things should still work even if I decide not to have any bindings in my item layouts.
The text was updated successfully, but these errors were encountered:
The check is to ensure that the variable you are trying to bind to actually exsists in the layout. This way you immedatly know if you forgot to add it or use the wrong one. If you don't want a binding you can use ItemView.BINDING_VARIABLE_NONE.
There is currently a bug in the databinding library where if you declare a varibale but not use it in a binding it will return that it doesn't exist. This will be fixed in the next release.
I realize this is a bit counter intuitive to the intent of the library, but I ran into the following exception when I had no bindings defined in my Item view model:
I ran into the exception while stubbing classes and layouts out to test the library. When I added a binding in my layout, everything worked fine. It seems like things should still work even if I decide not to have any bindings in my item layouts.
The text was updated successfully, but these errors were encountered: