org.neogroup.warp.data.query.traits.HasHavingConditions Maven / Gradle / Ivy
package org.neogroup.warp.data.query.traits;
import org.neogroup.warp.data.query.conditions.*;
import org.neogroup.warp.data.query.fields.Field;
import java.util.Collection;
public interface HasHavingConditions {
ConditionGroup getHavingConditions();
R setHavingConditions (ConditionGroup conditionGroup);
default ConditionGroupConnector getHavingConnector() {
return getHavingConditions().getConnector();
}
default R setHavingConnector(ConditionGroupConnector connector) {
getHavingConditions().setConnector(connector);
return (R)this;
}
default R clearHavingConditions() {
getHavingConditions().clearConditions();
return (R)this;
}
default boolean hasHavingConditions() {
return getHavingConditions().isEmpty();
}
default R having(Condition condition) {
getHavingConditions().addCondition(condition);
return (R)this;
}
default R having(String field, Object value) {
getHavingConditions().on(field, value);
return (R)this;
}
default R having(Field field, Object value) {
getHavingConditions().on(field, value);
return (R)this;
}
default R having(String field, ConditionOperator operator, Object value) {
getHavingConditions().on(field, operator, value);
return (R)this;
}
default R having(Field field, ConditionOperator operator, Object value) {
getHavingConditions().on(field, operator, value);
return (R)this;
}
default R havingGroup(ConditionGroup condition) {
getHavingConditions().onGroup(condition);
return (R)this;
}
default R havingRaw(RawCondition condition) {
getHavingConditions().onRaw(condition);
return (R)this;
}
default R havingField(String field1, String field2) {
getHavingConditions().onField(field1, field2);
return (R)this;
}
default R havingField(Field field1, Field field2) {
getHavingConditions().onField(field1, field2);
return (R)this;
}
default R havingField(String field1, ConditionOperator operator, String field2) {
getHavingConditions().onField(field1, operator, field2);
return (R)this;
}
default R havingField(Field field1, ConditionOperator operator, Field field2) {
getHavingConditions().onField(field1, operator, field2);
return (R)this;
}
default R havingNull(String field) {
getHavingConditions().onNull(field);
return (R)this;
}
default R havingNull(Field field) {
getHavingConditions().onNull(field);
return (R)this;
}
default R havingNotNull(String field) {
getHavingConditions().onNotNull(field);
return (R)this;
}
default R havingNotNull(Field field) {
getHavingConditions().onNotNull(field);
return (R)this;
}
default R havingIn(String field, Collection
© 2015 - 2025 Weber Informatics LLC | Privacy Policy