Skip to content

Commit

Permalink
Revert "add summaries and status into collection"
Browse files Browse the repository at this point in the history
This reverts commit 612fc35.
  • Loading branch information
HavierD committed May 21, 2024
1 parent 612fc35 commit 39241f6
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 31 deletions.
13 changes: 0 additions & 13 deletions features/src/main/resources/schema/features/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -592,8 +592,6 @@ components:
type: string
description: a description of the features in the collection
example: An address.
summaries:
$ref: '#/components/schemas/summaries'
links:
type: array
example:
Expand Down Expand Up @@ -903,17 +901,6 @@ components:
type: array
items:
type: number
summaries:
type: object
properties:
score:
type: string
description: score of the data
example: 0.8
status:
type: string
description: status of the data
example: onGoing
timeStamp:
type: string
description: This property indicates the time and date when the response was generated.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,14 +90,6 @@ default <F extends StacCollectionModel> Collection getCollection(F m, String hos
.collect(Collectors.toList()));
}

if (m.getSummaries() != null) {
var summariesModel= m.getSummaries();
Summaries summaries = new Summaries();
summaries.setScore(String.valueOf(summariesModel.getScore()));
summaries.setStatus(summariesModel.getStatus());
collection.setSummaries(summaries);
}

return collection;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,7 @@ public enum CQLCollectionsField {
category(StacBasicField.DiscoveryCategories.searchField, StacBasicField.DiscoveryCategories.displayField),
providers(StacBasicField.Providers.searchField, StacBasicField.Providers.displayField),
discovery_categories(StacBasicField.DiscoveryCategories.searchField, StacBasicField.DiscoveryCategories.displayField),
id(StacBasicField.UUID.searchField, StacBasicField.UUID.displayField),
links(StacBasicField.Links.searchField, StacBasicField.Links.displayField),
status(StacSummeries.Status.searchField, StacSummeries.Status.displayField),
;
id(StacBasicField.UUID.searchField, StacBasicField.UUID.displayField);

private final String searchField;
private final String displayField;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ public enum StacBasicField {
DiscoveryCategories(
"discovery_categories", // This result in the whole themes section return
"summaries.discovery_categories"
),
Links("links", "links")
;
);

public final String searchField; // Field in STAC object
public final String displayField; // Field that is named externally
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,8 @@ public enum StacSummeries {
Temporal("summaries.temporal", "extent.temporal", List.of(TemporalStart, TemporalEnd)),
UpdateFrequency("summaries.update_frequency", "summaries.update_frequency"),
DatasetProvider("summaries.dataset_provider", "summaries.dataset_provider"),
DatasetGroup("summaries.dataset_group", "summaries.dataset_group"),
Status("summaries.status", "summaries.status")
;
DatasetGroup("summaries.dataset_group", "summaries.dataset_group");

public final String searchField;
public final String displayField;
public final List<StacSummeries> subfields;
Expand Down

0 comments on commit 39241f6

Please sign in to comment.