David Price

Moved BIND of variable to before first use of variable

...@@ -20,65 +20,70 @@ ...@@ -20,65 +20,70 @@
20 <http://www.epim.no/schemas/mprml/1#FacilityIdentifierStruct> 20 <http://www.epim.no/schemas/mprml/1#FacilityIdentifierStruct>
21 spin:rule 21 spin:rule
22 [ rdf:type sp:Construct ; 22 [ rdf:type sp:Construct ;
23 - rdfs:comment """STEP 00010 Record the Facility that has the flows - kind is \"licence\" 23 + rdfs:comment """STEP 00008 Record the Facility that has the flows - kind is \"company\" or \"commercial entity\" - assumed to be an OperatingCompany
24 Nothing is done with the namingSystem!"""^^xsd:string ; 24 Nothing is done with the namingSystem!"""^^xsd:string ;
25 sp:templates ([ sp:object spin:_this ; 25 sp:templates ([ sp:object spin:_this ;
26 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 26 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
27 sp:subject 27 sp:subject
28 - [ sp:varName "licence"^^xsd:string 28 + [ sp:varName "company"^^xsd:string
29 ] 29 ]
30 ] [ sp:object 30 ] [ sp:object
31 - [ sp:varName "licenceLabel"^^xsd:string 31 + [ sp:varName "companyLabel"^^xsd:string
32 ] ; 32 ] ;
33 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ; 33 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
34 sp:subject spin:_this 34 sp:subject spin:_this
35 ]) ; 35 ]) ;
36 - sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_licence> ; 36 + sp:where ([ rdf:type sp:Union ;
37 + sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_company> ;
38 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
39 + sp:subject spin:_this
40 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_commercialentity> ;
37 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 41 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
38 sp:subject spin:_this 42 sp:subject spin:_this
43 + ]))
39 ] [ sp:object 44 ] [ sp:object
40 - [ sp:varName "licenceName"^^xsd:string 45 + [ sp:varName "companyName"^^xsd:string
41 ] ; 46 ] ;
42 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 47 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
43 sp:subject spin:_this 48 sp:subject spin:_this
44 ] [ rdf:type sp:NamedGraph ; 49 ] [ rdf:type sp:NamedGraph ;
45 - sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#Licence> ; 50 + sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#OperatingCompany> ;
46 sp:predicate rdf:type ; 51 sp:predicate rdf:type ;
47 sp:subject 52 sp:subject
48 - [ sp:varName "licence"^^xsd:string 53 + [ sp:varName "company"^^xsd:string
49 ] 54 ]
50 ] [ sp:object 55 ] [ sp:object
51 - [ sp:varName "licenceName"^^xsd:string 56 + [ sp:varName "companyName"^^xsd:string
52 ] ; 57 ] ;
53 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ; 58 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
54 sp:subject 59 sp:subject
55 - [ sp:varName "licence"^^xsd:string 60 + [ sp:varName "company"^^xsd:string
56 ] 61 ]
57 ] [ sp:object 62 ] [ sp:object
58 - [ sp:varName "licenceId"^^xsd:string 63 + [ sp:varName "companyId"^^xsd:string
59 ] ; 64 ] ;
60 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ; 65 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
61 sp:subject 66 sp:subject
62 - [ sp:varName "livence"^^xsd:string 67 + [ sp:varName "company"^^xsd:string
63 ] 68 ]
64 ]) ; 69 ]) ;
65 sp:graphNameNode <http://www.reportinghub.no/np/data/npd> 70 sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
66 ] [ rdf:type sp:Bind ; 71 ] [ rdf:type sp:Bind ;
67 sp:expression 72 sp:expression
68 [ rdf:type fn:concat ; 73 [ rdf:type fn:concat ;
69 - sp:arg1 "licence-" ; 74 + sp:arg1 "company-" ;
70 - sp:arg2 [ sp:varName "licenceId"^^xsd:string 75 + sp:arg2 [ sp:varName "companyId"^^xsd:string
71 ] 76 ]
72 ] ; 77 ] ;
73 sp:variable 78 sp:variable
74 - [ sp:varName "licenceLabel"^^xsd:string 79 + [ sp:varName "companyLabel"^^xsd:string
75 ] 80 ]
76 ]) 81 ])
77 ] ; 82 ] ;
78 spin:rule 83 spin:rule
79 [ rdf:type sp:Construct ; 84 [ rdf:type sp:Construct ;
80 - rdfs:comment """STEP 00014 Record the Facility that has the flows - not in the NPD Fact Pages - not already in the file 85 + rdfs:comment """STEP 00013 Record the Facility that has the flows - not in the NPD Fact Pages - not already in the file
81 -Naming system not supplied"""^^xsd:string ; 86 +Naming system supplied"""^^xsd:string ;
82 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Facility> ; 87 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Facility> ;
83 sp:predicate rdf:type ; 88 sp:predicate rdf:type ;
84 sp:subject 89 sp:subject
...@@ -121,13 +126,11 @@ Naming system not supplied"""^^xsd:string ; ...@@ -121,13 +126,11 @@ Naming system not supplied"""^^xsd:string ;
121 ] ; 126 ] ;
122 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 127 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
123 sp:subject spin:_this 128 sp:subject spin:_this
124 - ] [ rdf:type sp:NotExists ; 129 + ] [ sp:object
125 - sp:elements ([ sp:object
126 [ sp:varName "namingSystem"^^xsd:string 130 [ sp:varName "namingSystem"^^xsd:string
127 ] ; 131 ] ;
128 sp:predicate <http://www.epim.no/schemas/mprml/1#namingSystem> ; 132 sp:predicate <http://www.epim.no/schemas/mprml/1#namingSystem> ;
129 sp:subject spin:_this 133 sp:subject spin:_this
130 - ])
131 ] [ rdf:type sp:NotExists ; 134 ] [ rdf:type sp:NotExists ;
132 sp:elements ([ sp:object spin:_this ; 135 sp:elements ([ sp:object spin:_this ;
133 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 136 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
...@@ -147,7 +150,8 @@ Naming system not supplied"""^^xsd:string ; ...@@ -147,7 +150,8 @@ Naming system not supplied"""^^xsd:string ;
147 ] [ rdf:type sp:Bind ; 150 ] [ rdf:type sp:Bind ;
148 sp:expression 151 sp:expression
149 [ rdf:type ep-dpr-spin-lib:buildSmallFacilityURI ; 152 [ rdf:type ep-dpr-spin-lib:buildSmallFacilityURI ;
150 - sp:arg1 "" ; 153 + sp:arg1 [ sp:varName "namingSystem"^^xsd:string
154 + ] ;
151 sp:arg2 [ sp:varName "facilityName"^^xsd:string 155 sp:arg2 [ sp:varName "facilityName"^^xsd:string
152 ] 156 ]
153 ] ; 157 ] ;
...@@ -158,115 +162,69 @@ Naming system not supplied"""^^xsd:string ; ...@@ -158,115 +162,69 @@ Naming system not supplied"""^^xsd:string ;
158 ] ; 162 ] ;
159 spin:rule 163 spin:rule
160 [ rdf:type sp:Construct ; 164 [ rdf:type sp:Construct ;
161 - rdfs:comment """STEP 00004 Record the Facility that has the flows - kind is \"platform\" - assumed to be a MoveableFacility 165 + rdfs:comment """STEP 00001 Record the Facility that has the flows - kind is \"field\", etc.
162 Nothing is done with the namingSystem!"""^^xsd:string ; 166 Nothing is done with the namingSystem!"""^^xsd:string ;
163 sp:templates ([ sp:object spin:_this ; 167 sp:templates ([ sp:object spin:_this ;
164 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 168 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
165 sp:subject 169 sp:subject
166 - [ sp:varName "platform"^^xsd:string 170 + [ sp:varName "field"^^xsd:string
167 ] 171 ]
168 ] [ sp:object 172 ] [ sp:object
169 - [ sp:varName "platformLabel"^^xsd:string 173 + [ sp:varName "fieldLabel"^^xsd:string
170 ] ; 174 ] ;
171 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ; 175 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
172 sp:subject spin:_this 176 sp:subject spin:_this
173 ]) ; 177 ]) ;
174 - sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_platform> ; 178 + sp:where ([ rdf:type sp:Union ;
179 + sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
175 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 180 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
176 sp:subject spin:_this 181 sp:subject spin:_this
177 - ] [ sp:object 182 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field-part> ;
178 - [ sp:varName "platformName"^^xsd:string 183 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
179 - ] ;
180 - sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
181 sp:subject spin:_this 184 sp:subject spin:_this
182 - ] [ rdf:type sp:NamedGraph ; 185 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field-group> ;
183 - sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/facility#MoveableFacility> ; 186 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
184 - sp:predicate rdf:type ;
185 - sp:subject
186 - [ sp:varName "platform"^^xsd:string
187 - ]
188 - ] [ sp:object
189 - [ sp:varName "platformName"^^xsd:string
190 - ] ;
191 - sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
192 - sp:subject
193 - [ sp:varName "platform"^^xsd:string
194 - ]
195 - ] [ sp:object
196 - [ sp:varName "platformId"^^xsd:string
197 - ] ;
198 - sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
199 - sp:subject
200 - [ sp:varName "platform"^^xsd:string
201 - ]
202 - ]) ;
203 - sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
204 - ] [ rdf:type sp:Bind ;
205 - sp:expression
206 - [ rdf:type fn:concat ;
207 - sp:arg1 "platform-" ;
208 - sp:arg2 [ sp:varName "platformId"^^xsd:string
209 - ]
210 - ] ;
211 - sp:variable
212 - [ sp:varName "platformLabel"^^xsd:string
213 - ]
214 - ])
215 - ] ;
216 - spin:rule
217 - [ rdf:type sp:Construct ;
218 - rdfs:comment """STEP 00005 Record the Facility that has the flows - kind is \"well\"
219 -Nothing is done with the namingSystem!"""^^xsd:string ;
220 - sp:templates ([ sp:object spin:_this ;
221 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
222 - sp:subject
223 - [ sp:varName "well"^^xsd:string
224 - ]
225 - ] [ sp:object
226 - [ sp:varName "wellLabel"^^xsd:string
227 - ] ;
228 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
229 sp:subject spin:_this 187 sp:subject spin:_this
230 - ]) ; 188 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field-area> ;
231 - sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_well> ;
232 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 189 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
233 sp:subject spin:_this 190 sp:subject spin:_this
191 + ]))
234 ] [ sp:object 192 ] [ sp:object
235 - [ sp:varName "wellName"^^xsd:string 193 + [ sp:varName "fieldName"^^xsd:string
236 ] ; 194 ] ;
237 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 195 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
238 sp:subject spin:_this 196 sp:subject spin:_this
239 ] [ rdf:type sp:NamedGraph ; 197 ] [ rdf:type sp:NamedGraph ;
240 - sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/well#Well> ; 198 + sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Field> ;
241 sp:predicate rdf:type ; 199 sp:predicate rdf:type ;
242 sp:subject 200 sp:subject
243 - [ sp:varName "well"^^xsd:string 201 + [ sp:varName "field"^^xsd:string
244 ] 202 ]
245 ] [ sp:object 203 ] [ sp:object
246 - [ sp:varName "wellName"^^xsd:string 204 + [ sp:varName "fieldName"^^xsd:string
247 ] ; 205 ] ;
248 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ; 206 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
249 sp:subject 207 sp:subject
250 - [ sp:varName "well"^^xsd:string 208 + [ sp:varName "field"^^xsd:string
251 ] 209 ]
252 ] [ sp:object 210 ] [ sp:object
253 - [ sp:varName "wellId"^^xsd:string 211 + [ sp:varName "fieldId"^^xsd:string
254 ] ; 212 ] ;
255 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ; 213 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
256 sp:subject 214 sp:subject
257 - [ sp:varName "well"^^xsd:string 215 + [ sp:varName "field"^^xsd:string
258 ] 216 ]
259 ]) ; 217 ]) ;
260 sp:graphNameNode <http://www.reportinghub.no/np/data/npd> 218 sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
261 ] [ rdf:type sp:Bind ; 219 ] [ rdf:type sp:Bind ;
262 sp:expression 220 sp:expression
263 [ rdf:type fn:concat ; 221 [ rdf:type fn:concat ;
264 - sp:arg1 "well-" ; 222 + sp:arg1 "field-" ;
265 - sp:arg2 [ sp:varName "wellId"^^xsd:string 223 + sp:arg2 [ sp:varName "fieldId"^^xsd:string
266 ] 224 ]
267 ] ; 225 ] ;
268 sp:variable 226 sp:variable
269 - [ sp:varName "wellLabel"^^xsd:string 227 + [ sp:varName "fieldLabel"^^xsd:string
270 ] 228 ]
271 ]) 229 ])
272 ] ; 230 ] ;
...@@ -329,210 +287,123 @@ Nothing is done with the namingSystem!"""^^xsd:string ; ...@@ -329,210 +287,123 @@ Nothing is done with the namingSystem!"""^^xsd:string ;
329 ] ; 287 ] ;
330 spin:rule 288 spin:rule
331 [ rdf:type sp:Construct ; 289 [ rdf:type sp:Construct ;
332 - rdfs:comment """STEP 00009 Record the Facility that has the flows - kind is \"company\" or \"commercial entity\" - assumed to be an ParentCompany 290 + rdfs:comment """STEP 00003 Record the Facility that has the flows - kind is \"platform\" - assumed to be a SurfaceFixedFacility
333 Nothing is done with the namingSystem!"""^^xsd:string ; 291 Nothing is done with the namingSystem!"""^^xsd:string ;
334 sp:templates ([ sp:object spin:_this ; 292 sp:templates ([ sp:object spin:_this ;
335 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 293 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
336 sp:subject 294 sp:subject
337 - [ sp:varName "company"^^xsd:string 295 + [ sp:varName "platform"^^xsd:string
338 ] 296 ]
339 ] [ sp:object 297 ] [ sp:object
340 - [ sp:varName "companyLabel"^^xsd:string 298 + [ sp:varName "platformLabel"^^xsd:string
341 ] ; 299 ] ;
342 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ; 300 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
343 sp:subject spin:_this 301 sp:subject spin:_this
344 ]) ; 302 ]) ;
345 - sp:where ([ rdf:type sp:Union ; 303 + sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_platform> ;
346 - sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_company> ;
347 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
348 - sp:subject spin:_this
349 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_commercialentity> ;
350 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 304 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
351 sp:subject spin:_this 305 sp:subject spin:_this
352 - ]))
353 ] [ sp:object 306 ] [ sp:object
354 - [ sp:varName "companyName"^^xsd:string 307 + [ sp:varName "platformName"^^xsd:string
355 ] ; 308 ] ;
356 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 309 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
357 sp:subject spin:_this 310 sp:subject spin:_this
358 ] [ rdf:type sp:NamedGraph ; 311 ] [ rdf:type sp:NamedGraph ;
359 - sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#ParentCompany> ; 312 + sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/facility#SurfaceFixedFacility> ;
360 sp:predicate rdf:type ; 313 sp:predicate rdf:type ;
361 sp:subject 314 sp:subject
362 - [ sp:varName "company"^^xsd:string 315 + [ sp:varName "platform"^^xsd:string
363 ] 316 ]
364 ] [ sp:object 317 ] [ sp:object
365 - [ sp:varName "companyName"^^xsd:string 318 + [ sp:varName "platformName"^^xsd:string
366 ] ; 319 ] ;
367 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ; 320 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
368 sp:subject 321 sp:subject
369 - [ sp:varName "company"^^xsd:string 322 + [ sp:varName "platform"^^xsd:string
370 ] 323 ]
371 ] [ sp:object 324 ] [ sp:object
372 - [ sp:varName "companyId"^^xsd:string 325 + [ sp:varName "platformId"^^xsd:string
373 ] ; 326 ] ;
374 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ; 327 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
375 sp:subject 328 sp:subject
376 - [ sp:varName "company"^^xsd:string 329 + [ sp:varName "platform"^^xsd:string
377 ] 330 ]
378 ]) ; 331 ]) ;
379 sp:graphNameNode <http://www.reportinghub.no/np/data/npd> 332 sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
380 ] [ rdf:type sp:Bind ; 333 ] [ rdf:type sp:Bind ;
381 sp:expression 334 sp:expression
382 [ rdf:type fn:concat ; 335 [ rdf:type fn:concat ;
383 - sp:arg1 "company-" ; 336 + sp:arg1 "platform-" ;
384 - sp:arg2 [ sp:varName "companyId"^^xsd:string 337 + sp:arg2 [ sp:varName "platformId"^^xsd:string
385 ] 338 ]
386 ] ; 339 ] ;
387 sp:variable 340 sp:variable
388 - [ sp:varName "companyLabel"^^xsd:string 341 + [ sp:varName "platformLabel"^^xsd:string
389 ] 342 ]
390 ]) 343 ])
391 ] ; 344 ] ;
392 spin:rule 345 spin:rule
393 [ rdf:type sp:Construct ; 346 [ rdf:type sp:Construct ;
394 - rdfs:comment """STEP 00006 Record the Facility that has the flows - kind is \"terminal\", \"pipeline\", \"flowline\", \"installation\", etc. 347 + rdfs:comment """STEP 00012 Record the Facility that has the flows - not in the NPD Fact Pages - not already in the file - a terminal
395 Nothing is done with the namingSystem!"""^^xsd:string ; 348 Nothing is done with the namingSystem!"""^^xsd:string ;
396 - sp:templates ([ sp:object spin:_this ; 349 + sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Facility> ;
350 + sp:predicate rdf:type ;
351 + sp:subject
352 + [ sp:varName "terminal"^^xsd:string
353 + ]
354 + ] [ sp:object <http://www.reportinghub.no/ep/schema/geography#Terminal> ;
355 + sp:predicate rdf:type ;
356 + sp:subject
357 + [ sp:varName "terminal"^^xsd:string
358 + ]
359 + ] [ sp:object
360 + [ sp:varName "facilityName"^^xsd:string
361 + ] ;
362 + sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
363 + sp:subject
364 + [ sp:varName "terminal"^^xsd:string
365 + ]
366 + ] [ sp:object spin:_this ;
397 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 367 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
398 sp:subject 368 sp:subject
399 - [ sp:varName "tuf"^^xsd:string 369 + [ sp:varName "terminal"^^xsd:string
400 ] 370 ]
401 ] [ sp:object 371 ] [ sp:object
402 - [ sp:varName "tufLabel"^^xsd:string 372 + [ sp:varName "facilityName"^^xsd:string
403 ] ; 373 ] ;
404 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ; 374 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
405 sp:subject spin:_this 375 sp:subject spin:_this
406 ]) ; 376 ]) ;
407 - sp:where ([ rdf:type sp:Union ; 377 + sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_terminal> ;
408 - sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_terminal> ;
409 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
410 - sp:subject spin:_this
411 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_pipeline> ;
412 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
413 - sp:subject spin:_this
414 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_flowline> ;
415 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
416 - sp:subject spin:_this
417 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_installation> ;
418 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
419 - sp:subject spin:_this
420 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_plant> ;
421 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
422 - sp:subject spin:_this
423 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_processingfacility> ;
424 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
425 - sp:subject spin:_this
426 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_trunkline> ;
427 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
428 - sp:subject spin:_this
429 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_storage> ;
430 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
431 - sp:subject spin:_this
432 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_plant-processing> ;
433 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 378 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
434 sp:subject spin:_this 379 sp:subject spin:_this
435 - ]))
436 ] [ sp:object 380 ] [ sp:object
437 - [ sp:varName "tufName"^^xsd:string 381 + [ sp:varName "facilityName"^^xsd:string
438 ] ; 382 ] ;
439 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 383 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
440 sp:subject spin:_this 384 sp:subject spin:_this
441 - ] [ rdf:type sp:NamedGraph ; 385 + ] [ rdf:type sp:NotExists ;
442 - sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#TUF> ; 386 + sp:elements ([ sp:object spin:_this ;
443 - sp:predicate rdf:type ; 387 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
444 - sp:subject
445 - [ sp:varName "tuf"^^xsd:string
446 - ]
447 - ] [ sp:object
448 - [ sp:varName "tufName"^^xsd:string
449 - ] ;
450 - sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
451 - sp:subject
452 - [ sp:varName "tuf"^^xsd:string
453 - ]
454 - ] [ sp:object
455 - [ sp:varName "tufId"^^xsd:string
456 - ] ;
457 - sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
458 sp:subject 388 sp:subject
459 - [ sp:varName "tuf"^^xsd:string 389 + [ sp:varName "something"^^xsd:string
460 ] 390 ]
461 - ]) ; 391 + ])
462 - sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
463 ] [ rdf:type sp:Bind ; 392 ] [ rdf:type sp:Bind ;
464 sp:expression 393 sp:expression
465 - [ rdf:type fn:concat ; 394 + [ rdf:type ep-dpr-spin-lib:buildTerminalURI ;
466 - sp:arg1 "tuf-" ; 395 + sp:arg1 [ sp:varName "facilityName"^^xsd:string
467 - sp:arg2 [ sp:varName "tufId"^^xsd:string
468 ] 396 ]
469 ] ; 397 ] ;
470 sp:variable 398 sp:variable
471 - [ sp:varName "tufLabel"^^xsd:string 399 + [ sp:varName "terminal"^^xsd:string
472 ] 400 ]
473 ]) 401 ])
474 ] ; 402 ] ;
475 spin:rule 403 spin:rule
476 [ rdf:type sp:Construct ; 404 [ rdf:type sp:Construct ;
477 - rdfs:comment """STEP 00002 Record the Facility that has the flows - kind is \"wellbore\" 405 + rdfs:comment """STEP 00014 Record the Facility that has the flows - not in the NPD Fact Pages - not already in the file
478 -Nothing is done with the namingSystem!"""^^xsd:string ; 406 +Naming system not supplied"""^^xsd:string ;
479 - sp:templates ([ sp:object spin:_this ;
480 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
481 - sp:subject
482 - [ sp:varName "wellBore"^^xsd:string
483 - ]
484 - ] [ sp:object
485 - [ sp:varName "wellBoreLabel"^^xsd:string
486 - ] ;
487 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
488 - sp:subject spin:_this
489 - ]) ;
490 - sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_wellbore> ;
491 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
492 - sp:subject spin:_this
493 - ] [ sp:object
494 - [ sp:varName "wellBoreName"^^xsd:string
495 - ] ;
496 - sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
497 - sp:subject spin:_this
498 - ] [ rdf:type sp:NamedGraph ;
499 - sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/well#WellBore> ;
500 - sp:predicate rdf:type ;
501 - sp:subject
502 - [ sp:varName "wellBore"^^xsd:string
503 - ]
504 - ] [ sp:object
505 - [ sp:varName "wellBoreName"^^xsd:string
506 - ] ;
507 - sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
508 - sp:subject
509 - [ sp:varName "wellBore"^^xsd:string
510 - ]
511 - ] [ sp:object
512 - [ sp:varName "wellBoreId"^^xsd:string
513 - ] ;
514 - sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
515 - sp:subject
516 - [ sp:varName "wellBore"^^xsd:string
517 - ]
518 - ]) ;
519 - sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
520 - ] [ rdf:type sp:Bind ;
521 - sp:expression
522 - [ rdf:type fn:concat ;
523 - sp:arg1 "wellbore-" ;
524 - sp:arg2 [ sp:varName "wellBoreId"^^xsd:string
525 - ]
526 - ] ;
527 - sp:variable
528 - [ sp:varName "wellBoreLabel"^^xsd:string
529 - ]
530 - ])
531 - ] ;
532 - spin:rule
533 - [ rdf:type sp:Construct ;
534 - rdfs:comment """STEP 00013 Record the Facility that has the flows - not in the NPD Fact Pages - not already in the file
535 -Naming system supplied"""^^xsd:string ;
536 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Facility> ; 407 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Facility> ;
537 sp:predicate rdf:type ; 408 sp:predicate rdf:type ;
538 sp:subject 409 sp:subject
...@@ -575,11 +446,13 @@ Naming system supplied"""^^xsd:string ; ...@@ -575,11 +446,13 @@ Naming system supplied"""^^xsd:string ;
575 ] ; 446 ] ;
576 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 447 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
577 sp:subject spin:_this 448 sp:subject spin:_this
578 - ] [ sp:object 449 + ] [ rdf:type sp:NotExists ;
450 + sp:elements ([ sp:object
579 [ sp:varName "namingSystem"^^xsd:string 451 [ sp:varName "namingSystem"^^xsd:string
580 ] ; 452 ] ;
581 sp:predicate <http://www.epim.no/schemas/mprml/1#namingSystem> ; 453 sp:predicate <http://www.epim.no/schemas/mprml/1#namingSystem> ;
582 sp:subject spin:_this 454 sp:subject spin:_this
455 + ])
583 ] [ rdf:type sp:NotExists ; 456 ] [ rdf:type sp:NotExists ;
584 sp:elements ([ sp:object spin:_this ; 457 sp:elements ([ sp:object spin:_this ;
585 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 458 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
...@@ -599,8 +472,7 @@ Naming system supplied"""^^xsd:string ; ...@@ -599,8 +472,7 @@ Naming system supplied"""^^xsd:string ;
599 ] [ rdf:type sp:Bind ; 472 ] [ rdf:type sp:Bind ;
600 sp:expression 473 sp:expression
601 [ rdf:type ep-dpr-spin-lib:buildSmallFacilityURI ; 474 [ rdf:type ep-dpr-spin-lib:buildSmallFacilityURI ;
602 - sp:arg1 [ sp:varName "namingSystem"^^xsd:string 475 + sp:arg1 "" ;
603 - ] ;
604 sp:arg2 [ sp:varName "facilityName"^^xsd:string 476 sp:arg2 [ sp:varName "facilityName"^^xsd:string
605 ] 477 ]
606 ] ; 478 ] ;
...@@ -611,127 +483,152 @@ Naming system supplied"""^^xsd:string ; ...@@ -611,127 +483,152 @@ Naming system supplied"""^^xsd:string ;
611 ] ; 483 ] ;
612 spin:rule 484 spin:rule
613 [ rdf:type sp:Construct ; 485 [ rdf:type sp:Construct ;
614 - rdfs:comment """STEP 00012 Record the Facility that has the flows - not in the NPD Fact Pages - not already in the file - a terminal 486 + rdfs:comment """STEP 00009 Record the Facility that has the flows - kind is \"company\" or \"commercial entity\" - assumed to be an ParentCompany
615 Nothing is done with the namingSystem!"""^^xsd:string ; 487 Nothing is done with the namingSystem!"""^^xsd:string ;
616 - sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Facility> ; 488 + sp:templates ([ sp:object spin:_this ;
617 - sp:predicate rdf:type ;
618 - sp:subject
619 - [ sp:varName "terminal"^^xsd:string
620 - ]
621 - ] [ sp:object <http://www.reportinghub.no/ep/schema/geography#Terminal> ;
622 - sp:predicate rdf:type ;
623 - sp:subject
624 - [ sp:varName "terminal"^^xsd:string
625 - ]
626 - ] [ sp:object
627 - [ sp:varName "facilityName"^^xsd:string
628 - ] ;
629 - sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
630 - sp:subject
631 - [ sp:varName "terminal"^^xsd:string
632 - ]
633 - ] [ sp:object spin:_this ;
634 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 489 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
635 sp:subject 490 sp:subject
636 - [ sp:varName "terminal"^^xsd:string 491 + [ sp:varName "company"^^xsd:string
637 ] 492 ]
638 ] [ sp:object 493 ] [ sp:object
639 - [ sp:varName "facilityName"^^xsd:string 494 + [ sp:varName "companyLabel"^^xsd:string
640 ] ; 495 ] ;
641 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ; 496 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
642 sp:subject spin:_this 497 sp:subject spin:_this
643 ]) ; 498 ]) ;
644 - sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_terminal> ; 499 + sp:where ([ rdf:type sp:Union ;
500 + sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_company> ;
645 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 501 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
646 sp:subject spin:_this 502 sp:subject spin:_this
503 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_commercialentity> ;
504 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
505 + sp:subject spin:_this
506 + ]))
647 ] [ sp:object 507 ] [ sp:object
648 - [ sp:varName "facilityName"^^xsd:string 508 + [ sp:varName "companyName"^^xsd:string
649 ] ; 509 ] ;
650 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 510 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
651 sp:subject spin:_this 511 sp:subject spin:_this
652 - ] [ rdf:type sp:NotExists ; 512 + ] [ rdf:type sp:NamedGraph ;
653 - sp:elements ([ sp:object spin:_this ; 513 + sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#ParentCompany> ;
654 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 514 + sp:predicate rdf:type ;
655 sp:subject 515 sp:subject
656 - [ sp:varName "something"^^xsd:string 516 + [ sp:varName "company"^^xsd:string
657 ] 517 ]
658 - ]) 518 + ] [ sp:object
519 + [ sp:varName "companyName"^^xsd:string
520 + ] ;
521 + sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
522 + sp:subject
523 + [ sp:varName "company"^^xsd:string
524 + ]
525 + ] [ sp:object
526 + [ sp:varName "companyId"^^xsd:string
527 + ] ;
528 + sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
529 + sp:subject
530 + [ sp:varName "company"^^xsd:string
531 + ]
532 + ]) ;
533 + sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
659 ] [ rdf:type sp:Bind ; 534 ] [ rdf:type sp:Bind ;
660 sp:expression 535 sp:expression
661 - [ rdf:type ep-dpr-spin-lib:buildTerminalURI ; 536 + [ rdf:type fn:concat ;
662 - sp:arg1 [ sp:varName "facilityName"^^xsd:string 537 + sp:arg1 "company-" ;
538 + sp:arg2 [ sp:varName "companyId"^^xsd:string
663 ] 539 ]
664 ] ; 540 ] ;
665 sp:variable 541 sp:variable
666 - [ sp:varName "terminal"^^xsd:string 542 + [ sp:varName "companyLabel"^^xsd:string
667 ] 543 ]
668 ]) 544 ])
669 ] ; 545 ] ;
670 spin:rule 546 spin:rule
671 [ rdf:type sp:Construct ; 547 [ rdf:type sp:Construct ;
672 - rdfs:comment """STEP 00008 Record the Facility that has the flows - kind is \"company\" or \"commercial entity\" - assumed to be an OperatingCompany 548 + rdfs:comment """STEP 00006 Record the Facility that has the flows - kind is \"terminal\", \"pipeline\", \"flowline\", \"installation\", etc.
673 Nothing is done with the namingSystem!"""^^xsd:string ; 549 Nothing is done with the namingSystem!"""^^xsd:string ;
674 sp:templates ([ sp:object spin:_this ; 550 sp:templates ([ sp:object spin:_this ;
675 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 551 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
676 sp:subject 552 sp:subject
677 - [ sp:varName "company"^^xsd:string 553 + [ sp:varName "tuf"^^xsd:string
678 ] 554 ]
679 ] [ sp:object 555 ] [ sp:object
680 - [ sp:varName "companyLabel"^^xsd:string 556 + [ sp:varName "tufLabel"^^xsd:string
681 ] ; 557 ] ;
682 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ; 558 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
683 sp:subject spin:_this 559 sp:subject spin:_this
684 ]) ; 560 ]) ;
685 sp:where ([ rdf:type sp:Union ; 561 sp:where ([ rdf:type sp:Union ;
686 - sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_company> ; 562 + sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_terminal> ;
687 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 563 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
688 sp:subject spin:_this 564 sp:subject spin:_this
689 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_commercialentity> ; 565 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_pipeline> ;
566 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
567 + sp:subject spin:_this
568 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_flowline> ;
569 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
570 + sp:subject spin:_this
571 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_installation> ;
572 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
573 + sp:subject spin:_this
574 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_plant> ;
575 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
576 + sp:subject spin:_this
577 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_processingfacility> ;
578 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
579 + sp:subject spin:_this
580 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_trunkline> ;
581 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
582 + sp:subject spin:_this
583 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_storage> ;
584 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
585 + sp:subject spin:_this
586 + ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_plant-processing> ;
690 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 587 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
691 sp:subject spin:_this 588 sp:subject spin:_this
692 ])) 589 ]))
693 ] [ sp:object 590 ] [ sp:object
694 - [ sp:varName "companyName"^^xsd:string 591 + [ sp:varName "tufName"^^xsd:string
695 ] ; 592 ] ;
696 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 593 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
697 sp:subject spin:_this 594 sp:subject spin:_this
698 ] [ rdf:type sp:NamedGraph ; 595 ] [ rdf:type sp:NamedGraph ;
699 - sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#OperatingCompany> ; 596 + sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#TUF> ;
700 sp:predicate rdf:type ; 597 sp:predicate rdf:type ;
701 sp:subject 598 sp:subject
702 - [ sp:varName "company"^^xsd:string 599 + [ sp:varName "tuf"^^xsd:string
703 ] 600 ]
704 ] [ sp:object 601 ] [ sp:object
705 - [ sp:varName "companyName"^^xsd:string 602 + [ sp:varName "tufName"^^xsd:string
706 ] ; 603 ] ;
707 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ; 604 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
708 sp:subject 605 sp:subject
709 - [ sp:varName "company"^^xsd:string 606 + [ sp:varName "tuf"^^xsd:string
710 ] 607 ]
711 ] [ sp:object 608 ] [ sp:object
712 - [ sp:varName "companyId"^^xsd:string 609 + [ sp:varName "tufId"^^xsd:string
713 ] ; 610 ] ;
714 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ; 611 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
715 sp:subject 612 sp:subject
716 - [ sp:varName "company"^^xsd:string 613 + [ sp:varName "tuf"^^xsd:string
717 ] 614 ]
718 ]) ; 615 ]) ;
719 sp:graphNameNode <http://www.reportinghub.no/np/data/npd> 616 sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
720 ] [ rdf:type sp:Bind ; 617 ] [ rdf:type sp:Bind ;
721 sp:expression 618 sp:expression
722 [ rdf:type fn:concat ; 619 [ rdf:type fn:concat ;
723 - sp:arg1 "company-" ; 620 + sp:arg1 "tuf-" ;
724 - sp:arg2 [ sp:varName "companyId"^^xsd:string 621 + sp:arg2 [ sp:varName "tufId"^^xsd:string
725 ] 622 ]
726 ] ; 623 ] ;
727 sp:variable 624 sp:variable
728 - [ sp:varName "companyLabel"^^xsd:string 625 + [ sp:varName "tufLabel"^^xsd:string
729 ] 626 ]
730 ]) 627 ])
731 ] ; 628 ] ;
732 spin:rule 629 spin:rule
733 [ rdf:type sp:Construct ; 630 [ rdf:type sp:Construct ;
734 - rdfs:comment """STEP 00003 Record the Facility that has the flows - kind is \"platform\" - assumed to be a SurfaceFixedFacility 631 + rdfs:comment """STEP 00004 Record the Facility that has the flows - kind is \"platform\" - assumed to be a MoveableFacility
735 Nothing is done with the namingSystem!"""^^xsd:string ; 632 Nothing is done with the namingSystem!"""^^xsd:string ;
736 sp:templates ([ sp:object spin:_this ; 633 sp:templates ([ sp:object spin:_this ;
737 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 634 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
...@@ -753,7 +650,7 @@ Nothing is done with the namingSystem!"""^^xsd:string ; ...@@ -753,7 +650,7 @@ Nothing is done with the namingSystem!"""^^xsd:string ;
753 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 650 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
754 sp:subject spin:_this 651 sp:subject spin:_this
755 ] [ rdf:type sp:NamedGraph ; 652 ] [ rdf:type sp:NamedGraph ;
756 - sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/facility#SurfaceFixedFacility> ; 653 + sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/facility#MoveableFacility> ;
757 sp:predicate rdf:type ; 654 sp:predicate rdf:type ;
758 sp:subject 655 sp:subject
759 [ sp:varName "platform"^^xsd:string 656 [ sp:varName "platform"^^xsd:string
...@@ -788,69 +685,172 @@ Nothing is done with the namingSystem!"""^^xsd:string ; ...@@ -788,69 +685,172 @@ Nothing is done with the namingSystem!"""^^xsd:string ;
788 ] ; 685 ] ;
789 spin:rule 686 spin:rule
790 [ rdf:type sp:Construct ; 687 [ rdf:type sp:Construct ;
791 - rdfs:comment """STEP 00001 Record the Facility that has the flows - kind is \"field\", etc. 688 + rdfs:comment """STEP 00010 Record the Facility that has the flows - kind is \"licence\"
792 Nothing is done with the namingSystem!"""^^xsd:string ; 689 Nothing is done with the namingSystem!"""^^xsd:string ;
793 sp:templates ([ sp:object spin:_this ; 690 sp:templates ([ sp:object spin:_this ;
794 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 691 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
795 sp:subject 692 sp:subject
796 - [ sp:varName "field"^^xsd:string 693 + [ sp:varName "licence"^^xsd:string
797 ] 694 ]
798 ] [ sp:object 695 ] [ sp:object
799 - [ sp:varName "fieldLabel"^^xsd:string 696 + [ sp:varName "licenceLabel"^^xsd:string
800 ] ; 697 ] ;
801 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ; 698 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
802 sp:subject spin:_this 699 sp:subject spin:_this
803 ]) ; 700 ]) ;
804 - sp:where ([ rdf:type sp:Union ; 701 + sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_licence> ;
805 - sp:elements (([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
806 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 702 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
807 sp:subject spin:_this 703 sp:subject spin:_this
808 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field-part> ; 704 + ] [ sp:object
809 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 705 + [ sp:varName "licenceName"^^xsd:string
706 + ] ;
707 + sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
810 sp:subject spin:_this 708 sp:subject spin:_this
811 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field-group> ; 709 + ] [ rdf:type sp:NamedGraph ;
710 + sp:elements ([ sp:object <http://www.reportinghub.no/np/schema/npd#Licence> ;
711 + sp:predicate rdf:type ;
712 + sp:subject
713 + [ sp:varName "licence"^^xsd:string
714 + ]
715 + ] [ sp:object
716 + [ sp:varName "licenceName"^^xsd:string
717 + ] ;
718 + sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
719 + sp:subject
720 + [ sp:varName "licence"^^xsd:string
721 + ]
722 + ] [ sp:object
723 + [ sp:varName "licenceId"^^xsd:string
724 + ] ;
725 + sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
726 + sp:subject
727 + [ sp:varName "livence"^^xsd:string
728 + ]
729 + ]) ;
730 + sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
731 + ] [ rdf:type sp:Bind ;
732 + sp:expression
733 + [ rdf:type fn:concat ;
734 + sp:arg1 "licence-" ;
735 + sp:arg2 [ sp:varName "licenceId"^^xsd:string
736 + ]
737 + ] ;
738 + sp:variable
739 + [ sp:varName "licenceLabel"^^xsd:string
740 + ]
741 + ])
742 + ] ;
743 + spin:rule
744 + [ rdf:type sp:Construct ;
745 + rdfs:comment """STEP 00002 Record the Facility that has the flows - kind is \"wellbore\"
746 +Nothing is done with the namingSystem!"""^^xsd:string ;
747 + sp:templates ([ sp:object spin:_this ;
748 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
749 + sp:subject
750 + [ sp:varName "wellBore"^^xsd:string
751 + ]
752 + ] [ sp:object
753 + [ sp:varName "wellBoreLabel"^^xsd:string
754 + ] ;
755 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
756 + sp:subject spin:_this
757 + ]) ;
758 + sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_wellbore> ;
812 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 759 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
813 sp:subject spin:_this 760 sp:subject spin:_this
814 - ]) ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_field-area> ; 761 + ] [ sp:object
762 + [ sp:varName "wellBoreName"^^xsd:string
763 + ] ;
764 + sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
765 + sp:subject spin:_this
766 + ] [ rdf:type sp:NamedGraph ;
767 + sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/well#WellBore> ;
768 + sp:predicate rdf:type ;
769 + sp:subject
770 + [ sp:varName "wellBore"^^xsd:string
771 + ]
772 + ] [ sp:object
773 + [ sp:varName "wellBoreName"^^xsd:string
774 + ] ;
775 + sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
776 + sp:subject
777 + [ sp:varName "wellBore"^^xsd:string
778 + ]
779 + ] [ sp:object
780 + [ sp:varName "wellBoreId"^^xsd:string
781 + ] ;
782 + sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
783 + sp:subject
784 + [ sp:varName "wellBore"^^xsd:string
785 + ]
786 + ]) ;
787 + sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
788 + ] [ rdf:type sp:Bind ;
789 + sp:expression
790 + [ rdf:type fn:concat ;
791 + sp:arg1 "wellbore-" ;
792 + sp:arg2 [ sp:varName "wellBoreId"^^xsd:string
793 + ]
794 + ] ;
795 + sp:variable
796 + [ sp:varName "wellBoreLabel"^^xsd:string
797 + ]
798 + ])
799 + ] ;
800 + spin:rule
801 + [ rdf:type sp:Construct ;
802 + rdfs:comment """STEP 00005 Record the Facility that has the flows - kind is \"well\"
803 +Nothing is done with the namingSystem!"""^^xsd:string ;
804 + sp:templates ([ sp:object spin:_this ;
805 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
806 + sp:subject
807 + [ sp:varName "well"^^xsd:string
808 + ]
809 + ] [ sp:object
810 + [ sp:varName "wellLabel"^^xsd:string
811 + ] ;
812 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
813 + sp:subject spin:_this
814 + ]) ;
815 + sp:where ([ sp:object <http://www.epim.no/schemas/mprml/1#RF_well> ;
815 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 816 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
816 sp:subject spin:_this 817 sp:subject spin:_this
817 - ]))
818 ] [ sp:object 818 ] [ sp:object
819 - [ sp:varName "fieldName"^^xsd:string 819 + [ sp:varName "wellName"^^xsd:string
820 ] ; 820 ] ;
821 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 821 sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
822 sp:subject spin:_this 822 sp:subject spin:_this
823 ] [ rdf:type sp:NamedGraph ; 823 ] [ rdf:type sp:NamedGraph ;
824 - sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/facility#Field> ; 824 + sp:elements ([ sp:object <http://www.reportinghub.no/ep/schema/well#Well> ;
825 sp:predicate rdf:type ; 825 sp:predicate rdf:type ;
826 sp:subject 826 sp:subject
827 - [ sp:varName "field"^^xsd:string 827 + [ sp:varName "well"^^xsd:string
828 ] 828 ]
829 ] [ sp:object 829 ] [ sp:object
830 - [ sp:varName "fieldName"^^xsd:string 830 + [ sp:varName "wellName"^^xsd:string
831 ] ; 831 ] ;
832 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ; 832 sp:predicate <http://www.reportinghub.no/np/schema/npd#name> ;
833 sp:subject 833 sp:subject
834 - [ sp:varName "field"^^xsd:string 834 + [ sp:varName "well"^^xsd:string
835 ] 835 ]
836 ] [ sp:object 836 ] [ sp:object
837 - [ sp:varName "fieldId"^^xsd:string 837 + [ sp:varName "wellId"^^xsd:string
838 ] ; 838 ] ;
839 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ; 839 sp:predicate <http://www.reportinghub.no/np/schema/npd#id> ;
840 sp:subject 840 sp:subject
841 - [ sp:varName "field"^^xsd:string 841 + [ sp:varName "well"^^xsd:string
842 ] 842 ]
843 ]) ; 843 ]) ;
844 sp:graphNameNode <http://www.reportinghub.no/np/data/npd> 844 sp:graphNameNode <http://www.reportinghub.no/np/data/npd>
845 ] [ rdf:type sp:Bind ; 845 ] [ rdf:type sp:Bind ;
846 sp:expression 846 sp:expression
847 [ rdf:type fn:concat ; 847 [ rdf:type fn:concat ;
848 - sp:arg1 "field-" ; 848 + sp:arg1 "well-" ;
849 - sp:arg2 [ sp:varName "fieldId"^^xsd:string 849 + sp:arg2 [ sp:varName "wellId"^^xsd:string
850 ] 850 ]
851 ] ; 851 ] ;
852 sp:variable 852 sp:variable
853 - [ sp:varName "fieldLabel"^^xsd:string 853 + [ sp:varName "wellLabel"^^xsd:string
854 ] 854 ]
855 ]) 855 ])
856 ] ; 856 ] ;
...@@ -895,13 +895,6 @@ Nothing is done with the namingSystem!"""^^xsd:string ; ...@@ -895,13 +895,6 @@ Nothing is done with the namingSystem!"""^^xsd:string ;
895 sp:subject 895 sp:subject
896 [ sp:varName "aFacilityIdentifierStructure"^^xsd:string 896 [ sp:varName "aFacilityIdentifierStructure"^^xsd:string
897 ] 897 ]
898 - ] [ sp:object
899 - [ sp:varName "reportingFacilityType"^^xsd:string
900 - ] ;
901 - sp:predicate rdf:type ;
902 - sp:subject
903 - [ sp:varName "facility"^^xsd:string
904 - ]
905 ] [ rdf:type sp:Bind ; 898 ] [ rdf:type sp:Bind ;
906 sp:expression 899 sp:expression
907 [ rdf:type ep-mpr-spin-lib:selectReportingFacilityType ; 900 [ rdf:type ep-mpr-spin-lib:selectReportingFacilityType ;
...@@ -911,10 +904,17 @@ Nothing is done with the namingSystem!"""^^xsd:string ; ...@@ -911,10 +904,17 @@ Nothing is done with the namingSystem!"""^^xsd:string ;
911 sp:variable 904 sp:variable
912 [ sp:varName "reportingFacilityType"^^xsd:string 905 [ sp:varName "reportingFacilityType"^^xsd:string
913 ] 906 ]
907 + ] [ sp:object
908 + [ sp:varName "reportingFacilityType"^^xsd:string
909 + ] ;
910 + sp:predicate rdf:type ;
911 + sp:subject
912 + [ sp:varName "facility"^^xsd:string
913 + ]
914 ]) 914 ])
915 ] . 915 ] .
916 916
917 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-facilityIdentifierStructure-v1.1.1> 917 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-facilityIdentifierStructure-v1.1.1>
918 rdf:type owl:Ontology ; 918 rdf:type owl:Ontology ;
919 - owl:imports <http://www.reportinghub.no/ep/transform/transform-helper-schema> , <http://www.reportinghub.no/ep/dpr/spin/1.1/lib> , <http://www.reportinghub.no/ep/mpr/spin/1.1/lib> , <http://www.epim.no/schemas/mprml/1> , <http://spinrdf.org/spin> ; 919 + owl:imports <http://spinrdf.org/spin> , <http://www.epim.no/schemas/mprml/1> , <http://www.reportinghub.no/ep/mpr/spin/1.1/lib> , <http://www.reportinghub.no/ep/dpr/spin/1.1/lib> , <http://www.reportinghub.no/ep/transform/transform-helper-schema> ;
920 owl:versionInfo "Created with TopBraid Composer"^^xsd:string . 920 owl:versionInfo "Created with TopBraid Composer"^^xsd:string .
......