io.pelle.mango.client.base.vo.query.AggregateQuery Maven / Gradle / Ivy
The newest version!
package io.pelle.mango.client.base.vo.query;
import io.pelle.mango.client.base.vo.IAttributeDescriptor;
import io.pelle.mango.client.base.vo.IVOEntity;
import java.util.ArrayList;
import java.util.List;
@SuppressWarnings("serial")
public class AggregateQuery extends BaseQuery> {
private List> sums = new ArrayList>();
public AggregateQuery() {
super();
}
public AggregateQuery(Class extends IVOEntity> from) {
getFroms().add(new Entity(aliasProvider, from.getName()));
}
public static final AggregateQuery aggregateFrom(Class entity) {
return new AggregateQuery(entity);
}
public AggregateQuery from(Class extends IVOEntity> from) {
getFroms().add(new Entity(aliasProvider, from.getName()));
return this;
}
@Override
public AggregateQuery getQuery() {
return this;
}
public AggregateQuery sum(IAttributeDescriptor> attributeDescriptor) {
sums.add(attributeDescriptor);
return this;
}
public List> getSums() {
return sums;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy