Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bugfix] Update codebase to latest web core #134

Merged
merged 3 commits into from
Apr 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ public abstract class Experiment<R extends ReportsGeneExpression> implements Ser
private final Species species;
private final ImmutableMap<String, R> id2ExpressedSamples;
private final ImmutableSet<String> experimentalFactorHeaders;
protected final ExperimentDesign experimentDesign;
private final ImmutableSet<String> pubMedIds;
private final ImmutableSet<String> dois;
private final String displayName;
Expand All @@ -44,7 +45,7 @@ public abstract class Experiment<R extends ReportsGeneExpression> implements Ser
private final ImmutableSet<String> alternativeViewDescriptions;
private final ExperimentDisplayDefaults experimentDisplayDefaults;
private final boolean isPrivate;
private String accessKey;
private final String accessKey;

public Experiment(
@NotNull ExperimentType type,
Expand Down Expand Up @@ -84,6 +85,7 @@ public Experiment(
this.lastUpdate = lastUpdate;
this.species = species;
this.technologyType = ImmutableSet.copyOf(technologyType);
this.experimentDesign = experimentDesign;
this.pubMedIds = pubMedIds.stream().sorted().collect(toImmutableSet());
this.dois = dois.stream().sorted().collect(toImmutableSet());
this.displayName = isBlank(displayName) ? accession : displayName;
Expand Down Expand Up @@ -122,6 +124,11 @@ public ExperimentType getType() {
return type;
}

@NotNull
public ExperimentDesign getExperimentDesign() {
return experimentDesign;
}

@NotNull
public ImmutableSet<String> getExperimentalFactorHeaders() {
return experimentalFactorHeaders;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ private AnalyticsSchemaField(String fieldName) {


public static AnalyticsSchemaField asAnalyticsSchemaField(BioentityPropertyName bioentityPropertyName) {
return bioentityPropertyName.isKeyword ?
return bioentityPropertyName != null && bioentityPropertyName.isKeyword ?
new AnalyticsSchemaField(String.format("keyword_%s", bioentityPropertyName.name)) :
IDENTIFIER_SEARCH;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import com.google.common.collect.ImmutableList;
import org.hamcrest.Matchers;
import org.jetbrains.annotations.Nullable;
import org.junit.Test;
import uk.ac.ebi.atlas.controllers.ResourceNotFoundException;
import uk.ac.ebi.atlas.model.download.ExternallyAvailableContent;
Expand Down