I'd like to know if in Android (Java) you can pass a photo using LiveData and a shared ViewModel between two fragments? I have hunted high and low online and can only find references online to something similar in Kotlin. Please excuse the basic question I'm a complete beginner. I have implemented working camera functionality within a fragment, but I would now like to display the resulting image in another fragment.
If this is possible, would I need to put the reference to the ViewModel in the onActivityResult() method in my existing fragment?
I am working with a bitmap so will I need to use Glide? Thanks for any suggestions.