Closed
Description
We find the cache
method to be quite useful, however, it's quite memory inefficient for caching single items since even when passing a capacity of 1, it will create an unbounded replay subject rather than one that actually has size 1.
Memory pressure being a major concern on Android, how would everyone feel about adding more overloads/alternatives to cache
that take a size, not just a capacity? e.g.:
Observable.cacheWithSize(1)
which would call ReplaySubject.createWithSize internally, using a BoundedState?