org.babyfish.jimmer.sql.cache.ParameterizedUsedCacheImpl Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jimmer-sql Show documentation
Show all versions of jimmer-sql Show documentation
A revolutionary ORM framework for both java and kotlin
The newest version!
package org.babyfish.jimmer.sql.cache;
import org.jetbrains.annotations.NotNull;
import java.util.Collection;
import java.util.Map;
import java.util.SortedMap;
class ParameterizedUsedCacheImpl extends UsedCacheImpl implements Cache.Parameterized {
public ParameterizedUsedCacheImpl(Cache.Parameterized raw, CacheOperator operator) {
super(raw, operator);
}
@Override
public @NotNull Map getAll(
@NotNull Collection keys,
@NotNull SortedMap parameterMap,
@NotNull CacheEnvironment env
) {
return loading(() -> {
Map valueMap = ((Cache.Parameterized)raw).getAll(keys, parameterMap, env);
for (V value : valueMap.values()) {
validateResult(value);
}
return valueMap;
});
}
}