android - RxJava and unmonitored download -
how handle in rxjava (i having hard time learning library).
i have url want download @ start of android app , want start if no 1 subscribing it. download may take amount of time possible user end on page relies on download of url, want activity/fragment subscribe outstanding observable.
i plan on tracking outstanding observables simple
map<string, observable>
so observers (activities/fragments) can know if url/string isn't in map stuff done. thinking of using publishsubject, according talk heard suggested not use subject's because should learn observable first before "shortcuts".
here example of asynchronous download performed once: with asyncsubject , concurrenthashmap
Comments
Post a Comment