Package org.aksw.commons.util.memoize
Class MemoizedBiFunctionImpl<I1,I2,O>
- java.lang.Object
-
- org.aksw.commons.util.memoize.MemoizedBiFunctionImpl<I1,I2,O>
-
- All Implemented Interfaces:
java.util.function.BiFunction<I1,I2,O>,Memoized<Map.Entry<I1,I2>,O>,MemoizedBiFunction<I1,I2,O>
public class MemoizedBiFunctionImpl<I1,I2,O> extends Object implements MemoizedBiFunction<I1,I2,O>
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Oapply(I1 a, I2 b)voidclearCache()Clear the cachestatic <I1,I2,O>
MemoizedBiFunction<I1,I2,O>create(java.util.function.BiFunction<I1,I2,O> delegate)Create with backing by a ConcurrentHashMapstatic <I1,I2,O>
MemoizedBiFunction<I1,I2,O>createNonConcurrent(java.util.function.BiFunction<I1,I2,O> delegate)Create with backing by a HashMapMap<Map.Entry<I1,I2>,O>getCache()Return a reference or copy to the memoized entries
-
-
-
Method Detail
-
getCache
public Map<Map.Entry<I1,I2>,O> getCache()
Description copied from interface:MemoizedReturn a reference or copy to the memoized entries
-
clearCache
public void clearCache()
Description copied from interface:MemoizedClear the cache- Specified by:
clearCachein interfaceMemoized<I1,I2>
-
create
public static <I1,I2,O> MemoizedBiFunction<I1,I2,O> create(java.util.function.BiFunction<I1,I2,O> delegate)
Create with backing by a ConcurrentHashMap
-
createNonConcurrent
public static <I1,I2,O> MemoizedBiFunction<I1,I2,O> createNonConcurrent(java.util.function.BiFunction<I1,I2,O> delegate)
Create with backing by a HashMap
-
-