-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
also add unresolved mode to ConceptColumnSelect
- Loading branch information
1 parent
b71635f
commit e86fbea
Showing
1 changed file
with
9 additions
and
10 deletions.
There are no files selected for viewing
19 changes: 9 additions & 10 deletions
19
...ava/com/bakdata/conquery/models/datasets/concepts/select/concept/ConceptColumnSelect.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,34 @@ | ||
package com.bakdata.conquery.models.datasets.concepts.select.concept; | ||
|
||
import java.util.Set; | ||
|
||
import com.bakdata.conquery.apiv1.query.concept.specific.CQConcept; | ||
import com.bakdata.conquery.io.cps.CPSType; | ||
import com.bakdata.conquery.models.datasets.concepts.select.Select; | ||
import com.bakdata.conquery.models.datasets.concepts.tree.TreeConcept; | ||
import com.bakdata.conquery.models.query.queryplan.aggregators.Aggregator; | ||
import com.bakdata.conquery.models.query.queryplan.aggregators.specific.value.ConceptElementsAggregator; | ||
import com.bakdata.conquery.models.query.resultinfo.SelectResultInfo; | ||
import com.bakdata.conquery.models.types.SemanticType; | ||
import com.bakdata.conquery.models.query.queryplan.aggregators.specific.value.ConceptValuesAggregator; | ||
import com.fasterxml.jackson.annotation.JsonBackReference; | ||
import com.fasterxml.jackson.annotation.JsonIgnore; | ||
import lombok.Setter; | ||
|
||
@CPSType(id = "CONCEPT_VALUES", base = Select.class) | ||
public class ConceptColumnSelect extends Select { | ||
|
||
private boolean resolved = false; | ||
|
||
@JsonBackReference | ||
@JsonIgnore | ||
@Setter | ||
private TreeConcept concept; | ||
|
||
@Override | ||
public Aggregator<?> createAggregator() { | ||
return new ConceptElementsAggregator(concept); | ||
} | ||
if(resolved){ | ||
return new ConceptElementsAggregator(concept); | ||
} | ||
|
||
@Override | ||
public SelectResultInfo getResultInfo(CQConcept cqConcept) { | ||
return new SelectResultInfo(this, cqConcept, Set.of(new SemanticType.ConceptColumnT(concept))); | ||
return new ConceptValuesAggregator(concept); | ||
} | ||
|
||
|
||
|
||
} |