works good! Softref holds the String pinning th...
# codereview
j
works good! Softref holds the String pinning the weakref 😛
Copy code
val bolCache: MutableMap<String, SoftReference<Pai2<RowVec, String>>> = WeakHashMap(0)
t
That's really bad...
Not sure what you're doing, but looks really scary. There's a a lot of possible issues.
j
the algorithm it serves is bollinger bands, something roughly like a rolling average of n rows with some transforms worth keeping from one row to the next.
it gets the job done, and exploits the one thing softref does well, holds garbage for a little while
elvis1, elvis2, and elvis3 all need to agree that the row is !null or the map follows through with getOrPut (again)