Does anybody knows some ObservableList implementat...
# getting-started
m
Does anybody knows some ObservableList implementation on Kotlin (or java 😞)?
r
JavaFX has a pretty comprehensive system of observables (including ObservableList), but I'm not sure how well they work outside the JavaFX world.
m
I need something on Android, ideally without additional dependencies
c
The
List<>
interface isn’t too huge, you could just wrap a normal list and add callbacks yourself. Especially by using interface delegation, you only need to override the methods that mutate the original list.
s
yeah i rolled my own, though i swear just the other day I swear I saw something that was an ObservableList but now I forget where or what it was
m
I found few, android.databinding, tornadofx and javafx all have implementations. But I'd like to avoid big dependencies for single class
s
yeh i don't think you'll want tornadofx or javafx dependencies in Android (unless i'm mistaken about ways those can be used).
r
Note that the TornadoFX one is the JavaFX one (TornadoFX is at it's core a Kotlin wrapper around JavaFX)