Skip to content

Commit

Permalink
network-schema.json: disallow 'network' in Node/Span, disallow additi…
Browse files Browse the repository at this point in the history
…onal in OrgRef/PhaseRef
  • Loading branch information
odscjen committed May 23, 2024
1 parent 41addf3 commit bd83ead
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 9 deletions.
4 changes: 4 additions & 0 deletions docs/reference/schema.md
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,8 @@ This component is referenced by the following properties:
- [`Span/supplier`](network-schema.json,/$defs/Span,supplier)
- [`Phase/funders`](network-schema.json,/$defs/Phase,funders)

Additional properties are not permitted within `OrganisationReference` objects.

Each `OrganisationReference` has the following fields:

::::{tab-set}
Expand Down Expand Up @@ -421,6 +423,8 @@ This component is referenced by the following properties:
- [`Span/phase`](network-schema.json,/$defs/Span,phase)
- [`Contract/relatedPhases`](network-schema.json,/$defs/Contract,relatedPhases)

Additional properties are not permitted within `PhaseReference` objects.

Each `PhaseReference` has the following fields:

::::{tab-set}
Expand Down
6 changes: 3 additions & 3 deletions examples/csv/nodes.csv
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
id,nodes/0/id,nodes/0/name,nodes/0/phase/id,nodes/0/phase/name,nodes/0/status,nodes/0/location,nodes/0/address/streetAddress,nodes/0/address/locality,nodes/0/address/region,nodes/0/address/postalCode,nodes/0/address/country,nodes/0/type,nodes/0/accessPoint,nodes/0/power,nodes/0/technologies,nodes/0/physicalInfrastructureProvider/id,nodes/0/physicalInfrastructureProvider/name
a096d627-72e1-4f9b-b129-951b1737bff4,1,Accra,1,NextGen Phase 1,operational,POINT (-0.174 5.625),Boundary Rd,Shiashie,Accra,12345,GH,pop,True,True,ip,GH-RGD-CS111111111,FibreCo
a096d627-72e1-4f9b-b129-951b1737bff4,2,Kumasi,1,NextGen Phase 1,operational,POINT (-1.628 6.711),Kejetia Road,Bantama,Kumasi,00000,GH,pop,False,True,ip,GH-RGD-CS111111111,FibreCo
id,nodes/0/id,nodes/0/name,nodes/0/phase/id,nodes/0/phase/name,nodes/0/status,nodes/0/location,nodes/0/address/streetAddress,nodes/0/address/locality,nodes/0/address/region,nodes/0/address/postalCode,nodes/0/address/country,nodes/0/type,nodes/0/accessPoint,nodes/0/power,nodes/0/technologies,nodes/0/physicalInfrastructureProvider/id,nodes/0/physicalInfrastructureProvider/name,nodes/0/location/type,nodes/0/location/coordinates
a096d627-72e1-4f9b-b129-951b1737bff4,1,Accra,1,NextGen Phase 1,operational,,Boundary Rd,Shiashie,Accra,12345,GH,pop,True,True,ip,GH-RGD-CS111111111,FibreCo,Point,-0.174;5.625
a096d627-72e1-4f9b-b129-951b1737bff4,2,Kumasi,1,NextGen Phase 1,operational,,Kejetia Road,Bantama,Kumasi,00000,GH,pop,False,True,ip,GH-RGD-CS111111111,FibreCo,Point,-1.628;6.711
4 changes: 2 additions & 2 deletions examples/csv/spans.csv
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
id,spans/0/id,spans/0/name,spans/0/phase/id,spans/0/phase/name,spans/0/status,spans/0/readyForServiceDate,spans/0/start,spans/0/end,spans/0/directed,spans/0/route,spans/0/physicalInfrastructureProvider/id,spans/0/physicalInfrastructureProvider/name,spans/0/supplier/id,spans/0/supplier/name,spans/0/transmissionMedium,spans/0/deployment,spans/0/deploymentDetails/description,spans/0/darkFibre,spans/0/fibreType,spans/0/fibreTypeDetails/fibreSubtype,spans/0/fibreTypeDetails/description,spans/0/fibreCount,spans/0/fibreLength,spans/0/technologies,spans/0/capacity,spans/0/capacityDetails/description,spans/0/countries
a096d627-72e1-4f9b-b129-951b1737bff4,1,Accra to Kumasi,1,NextGen Phase 1,operational,2018-01-01,1,2,False,"LINESTRING (-0.173 5.626, -0.178 5.807, -0.112 5.971, -0.211 5.963, -0.321 6.17, -0.488 6.29, -0.56 6.421, -0.752 6.533, -0.867 6.607, -1.101 6.585, -1.304 6.623, -1.461 6.727, -1.628 6.713)",GH-RGD-CS111111111,FibreCo,GH-RGD-CS333333333,ProjectCo,fibre,belowGround,Buried in ducts,True,G.652,G.652.D,"CABLED STANDARD ENHANCED SINGLEMODE FIBRE ESMF, LOW WATER PEAK SINGLE MODE FIBRE G.652.D, OS2",24,276000,sdh,4.976,2xSTM-16,GH
id,spans/0/id,spans/0/name,spans/0/phase/id,spans/0/phase/name,spans/0/status,spans/0/readyForServiceDate,spans/0/start,spans/0/end,spans/0/directed,spans/0/route,spans/0/physicalInfrastructureProvider/id,spans/0/physicalInfrastructureProvider/name,spans/0/supplier/id,spans/0/supplier/name,spans/0/transmissionMedium,spans/0/deployment,spans/0/deploymentDetails/description,spans/0/darkFibre,spans/0/fibreType,spans/0/fibreTypeDetails/fibreSubtype,spans/0/fibreTypeDetails/description,spans/0/fibreCount,spans/0/fibreLength,spans/0/technologies,spans/0/capacity,spans/0/capacityDetails/description,spans/0/countries,spans/0/route/type,spans/0/route/coordinates
a096d627-72e1-4f9b-b129-951b1737bff4,1,Accra to Kumasi,1,NextGen Phase 1,operational,2018-01-01,1,2,False,,GH-RGD-CS111111111,FibreCo,GH-RGD-CS333333333,ProjectCo,fibre,belowGround,Buried in ducts,True,G.652,G.652.D,"CABLED STANDARD ENHANCED SINGLEMODE FIBRE ESMF, LOW WATER PEAK SINGLE MODE FIBRE G.652.D, OS2",24,276000,sdh,4.976,2xSTM-16,GH,LineString,"-0.173,5.626;-0.178,5.807;-0.112,5.971;-0.211,5.963;-0.321,6.17;-0.488,6.29;-0.56,6.421;-0.752,6.533;-0.867,6.607;-1.101,6.585;-1.304,6.623;-1.461,6.727;-1.628,6.713"
16 changes: 12 additions & 4 deletions schema/network-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,10 @@
"required": [
"id"
],
"minProperties": 1
"minProperties": 1,
"propertyNames": {
"pattern": "^(?!(network$))"
}
},
"Span": {
"title": "Span",
Expand Down Expand Up @@ -751,7 +754,10 @@
"required": [
"id"
],
"minProperties": 1
"minProperties": 1,
"propertyNames": {
"pattern": "^(?!(network$))"
}
},
"Phase": {
"title": "Phase",
Expand Down Expand Up @@ -1241,7 +1247,8 @@
"required": [
"id"
],
"minProperties": 1
"minProperties": 1,
"additionalProperties": false
},
"PhaseReference": {
"title": "Phase reference",
Expand All @@ -1264,7 +1271,8 @@
"required": [
"id"
],
"minProperties": 1
"minProperties": 1,
"additionalProperties": false
},
"Address": {
"title": "Address",
Expand Down

0 comments on commit bd83ead

Please sign in to comment.