【发布时间】:2020-06-06 01:55:36
【问题描述】:
我在Restrictions.in 方法中使用List 对象,现在我必须在Restrictions.like 使用这个案例
但是Restrictions.like 没有收到List 参数。我怎么解决这个问题?
我的代码在底部:
public void setPhones(Set<String> phones) {
this.phones.addAll(phones);
if (!this.phones.isEmpty()) {
aliases.add(new QueryAlias("profile", "profile"));
criterions.add(Restrictions.like("profile.phone", this.phones));
}
}
【问题讨论】:
标签: java spring hibernate criteria dropwizard