Package org.aksw.commons.util.memoize
Class MemoizedSupplierImpl<T>
- java.lang.Object
-
- org.aksw.commons.util.memoize.MemoizedSupplierImpl<T>
-
- All Implemented Interfaces:
java.util.function.Supplier<T>,Memoized<Void,T>,MemoizedSupplier<T>
public class MemoizedSupplierImpl<T> extends Object implements MemoizedSupplier<T>
-
-
Constructor Summary
Constructors Constructor Description MemoizedSupplierImpl(java.util.function.Supplier<T> supplier)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclearCache()Clear the cacheTget()Map<Void,T>getCache()Return a reference or copy to the memoized entriesstatic <T> MemoizedSupplier<T>of(java.util.function.Supplier<T> supplier)
-
-
-
Constructor Detail
-
MemoizedSupplierImpl
public MemoizedSupplierImpl(java.util.function.Supplier<T> supplier)
-
-
Method Detail
-
of
public static <T> MemoizedSupplier<T> of(java.util.function.Supplier<T> supplier)
-
getCache
public Map<Void,T> 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<Void,T>
-
-