io.ebeaninternal.api.CacheIdLookupMany Maven / Gradle / Ivy
package io.ebeaninternal.api;
import io.ebeaninternal.server.expression.IdInCommon;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
/**
* Used for bean cache lookup with where ids in expression.
*/
public final class CacheIdLookupMany implements CacheIdLookup {
private final IdInCommon idInExpression;
private int remaining;
public CacheIdLookupMany(IdInCommon idInExpression) {
this.idInExpression = idInExpression;
}
/**
* Return the Id values for the in expression.
*/
@Override
public Collection> idValues() {
return idInExpression.idValues();
}
/**
* Process the hits returning the beans fetched from cache and
* adjusting the in expression (to not fetch the hits).
*/
@Override
public List removeHits(BeanCacheResult cacheResult) {
Set
© 2015 - 2024 Weber Informatics LLC | Privacy Policy