I have a variable in a fragment that will change several times throughout the fragment of life. This is caused by user interface interaction, so I thought it would be nice to use Observable to store it, instead of doing all the updated views as fields and changing my user interfaces from the setter.
The value should be updated using another method (mainly the installer, which should call onNext() for the subscriber), and not through the observable itself. Is there any way to do this using RxJava design?
In other words, I want to have an Observable field and give it new values ββto emit (calling onNext() for my subscribers) from another method in the class.
java android rx-java
Steven schoen
source share