Skip to content

Commit

Permalink
refactoring by instances of resultSets
Browse files Browse the repository at this point in the history
  • Loading branch information
costero-e committed Feb 21, 2025
1 parent 9e17cc1 commit 494cf6f
Show file tree
Hide file tree
Showing 4 changed files with 93 additions and 135 deletions.
16 changes: 2 additions & 14 deletions framework/json/responses/beaconResultsetsResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,8 @@
"description": "Information about the response that could be relevant for the Beacon client in order to interpret the results."
},
"response": {
"oneOf": [
{
"$ref": "./sections/beaconBooleanResultsets.json",
"description": "Response for queries that recovers any result."
},
{
"$ref": "./sections/beaconCountResultsets.json",
"description": "Response for queries that recovers any result."
},
{
"$ref": "./sections/beaconResultsets.json",
"description": "Response for queries that recovers any result."
}
]
"$ref": "./sections/beaconResultsets.json",
"description": "Response for queries that recovers any result."
},
"responseSummary": {
"$ref": "./sections/beaconSummaryResponseSection.json",
Expand Down
63 changes: 0 additions & 63 deletions framework/json/responses/sections/beaconBooleanResultsets.json

This file was deleted.

58 changes: 0 additions & 58 deletions framework/json/responses/sections/beaconCountResultsets.json

This file was deleted.

91 changes: 91 additions & 0 deletions framework/json/responses/sections/beaconResultsets.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,97 @@
"returnedGranularity"
],
"type": "object"
},
"CountInstance": {
"additionalProperties": true,
"properties": {
"exists": {
"type": "boolean"
},
"id": {
"description": "id of the resultset",
"example": "datasetA",
"type": "string"
},
"info": {
"description": "Additional details that could be of interest about the Resultset. Provided to clearly enclose any attribute that is not part of the Beacon specification.",
"type": "object"
},
"results": {
"items": {
"type": "object"
},
"minItems": 0,
"type": "array"
},
"resultsCount": {
"description": "Number of results in this Resultset.",
"type": "integer"
},
"resultsHandovers": {
"$ref": "../../common/beaconCommonComponents.json#/$defs/ListOfHandovers",
"description": "List of handovers that apply to this resultset, not to the whole Beacon or to a result in particular."
},
"returnedGranularity": { "const": "record" },
"setType": {
"default": "dataset",
"description": "Entry type of resultSet. It SHOULD MATCH an entry type declared as collection in the Beacon configuration.",
"type": "string"
}
},
"required": [
"id",
"setType",
"exists",
"resultsCount",
"returnedGranularity"
],
"type": "object"
},
"BooleanInstance": {
"additionalProperties": true,
"properties": {
"exists": {
"type": "boolean"
},
"id": {
"description": "id of the resultset",
"example": "datasetA",
"type": "string"
},
"info": {
"description": "Additional details that could be of interest about the Resultset. Provided to clearly enclose any attribute that is not part of the Beacon specification.",
"type": "object"
},
"results": {
"items": {
"type": "object"
},
"minItems": 0,
"type": "array"
},
"resultsCount": {
"description": "Number of results in this Resultset.",
"type": "integer"
},
"resultsHandovers": {
"$ref": "../../common/beaconCommonComponents.json#/$defs/ListOfHandovers",
"description": "List of handovers that apply to this resultset, not to the whole Beacon or to a result in particular."
},
"returnedGranularity": { "const": "boolean" },
"setType": {
"default": "dataset",
"description": "Entry type of resultSet. It SHOULD MATCH an entry type declared as collection in the Beacon configuration.",
"type": "string"
}
},
"required": [
"id",
"setType",
"exists",
"returnedGranularity"
],
"type": "object"
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema",
Expand Down

0 comments on commit 494cf6f

Please sign in to comment.