_filter(0, clone, false);
return true;
}
public boolean drillDown(DataSetGroup op) {
ColumnGroup cg = op.getColumnGroup();
if (cg == null) throw new RuntimeException("Group ops requires to specify a pivot column.");
if (op.getSelectedIntervalNames().isEmpty()) throw new RuntimeException("Group intervals not specified");
// Avoid duplicates
for (DataSetGroup next : lookupCurrent.getOperationList(DataSetGroup.class)) {
if (op.equals(next)) {
return false;
}
}
// Get the latest group op. for the target column being selected.
int lastSelection = lookupCurrent.getLastGroupOpIndex(0, null, true) + 1;
int targetGroup = lookupCurrent.getLastGroupOpIndex(lastSelection, cg.getColumnId(), false);
// If the selection does not exists just add it.
if (targetGroup == -1) {
DataSetGroup clone = op.cloneInstance();
clone.getGroupFunctions().clear();