David Leal

Merge branch 'MPR_period_date'

...@@ -22,13 +22,27 @@ ...@@ -22,13 +22,27 @@
22 <http://www.epim.no/schemas/mprml/1#A_Global-Objects> 22 <http://www.epim.no/schemas/mprml/1#A_Global-Objects>
23 spin:rule 23 spin:rule
24 [ rdf:type sp:Construct ; 24 [ rdf:type sp:Construct ;
25 - rdfs:comment "STEP 20050 Set the context facility - installation is always specified"^^xsd:string ; 25 + rdfs:comment "STEP 20032 Inherit start dates from the report context if necessary"^^xsd:string ;
26 sp:templates ([ sp:object 26 sp:templates ([ sp:object
27 - [ sp:varName "contextFacility"^^xsd:string 27 + [ sp:varName "dateStart"^^xsd:string
28 ] ; 28 ] ;
29 - sp:predicate <http://www.reportinghub.no/ep/schema/geography#locatedWithin> ; 29 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
30 sp:subject 30 sp:subject
31 - [ sp:varName "productionFacility"^^xsd:string 31 + [ sp:varName "productionFlow"^^xsd:string
32 + ]
33 + ] [ sp:object
34 + [ sp:varName "dateStart"^^xsd:string
35 + ] ;
36 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
37 + sp:subject
38 + [ sp:varName "productionInventory"^^xsd:string
39 + ]
40 + ] [ sp:object
41 + [ sp:varName "dateStart"^^xsd:string
42 + ] ;
43 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
44 + sp:subject
45 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
32 ] 46 ]
33 ]) ; 47 ]) ;
34 sp:where ([ sp:object 48 sp:where ([ sp:object
...@@ -36,270 +50,192 @@ ...@@ -36,270 +50,192 @@
36 ] ; 50 ] ;
37 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 51 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
38 sp:subject spin:_this 52 sp:subject spin:_this
53 + ] [ sp:object
54 + [ sp:varName "dateStart"^^xsd:string
55 + ] ;
56 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ;
57 + sp:subject spin:_this
39 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ; 58 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
40 sp:predicate rdf:type ; 59 sp:predicate rdf:type ;
41 sp:subject 60 sp:subject
42 [ sp:varName "productVolumeRef"^^xsd:string 61 [ sp:varName "productVolumeRef"^^xsd:string
43 ] 62 ]
63 + ] [ rdf:type sp:NotExists ;
64 + sp:elements ([ sp:object
65 + [ sp:varName "dateStartx"^^xsd:string
66 + ] ;
67 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
68 + sp:subject
69 + [ sp:varName "productVolumeRef"^^xsd:string
70 + ]
71 + ])
72 + ] [ rdf:type sp:NotExists ;
73 + sp:elements ([ sp:object
74 + [ sp:varName "dTimStartx"^^xsd:string
75 + ] ;
76 + sp:predicate <http://www.epim.no/schemas/mprml/1#dTimStart> ;
77 + sp:subject
78 + [ sp:varName "productVolumeRef"^^xsd:string
79 + ]
80 + ])
44 ] [ sp:object 81 ] [ sp:object
45 - [ sp:varName "installationRef"^^xsd:string
46 - ] ;
47 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
48 - sp:subject
49 [ sp:varName "productVolumeRef"^^xsd:string 82 [ sp:varName "productVolumeRef"^^xsd:string
50 - ]
51 - ] [ sp:object
52 - [ sp:varName "installationRef"^^xsd:string
53 ] ; 83 ] ;
54 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 84 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
55 sp:subject 85 sp:subject
56 - [ sp:varName "productionFacility"^^xsd:string 86 + [ sp:varName "productionFlow"^^xsd:string
57 ] 87 ]
58 - ] [ sp:object 88 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlow> ;
59 - [ sp:varName "contextFacilityRef"^^xsd:string 89 + sp:predicate rdf:type ;
60 - ] ;
61 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ;
62 sp:subject 90 sp:subject
63 - [ sp:varName "productVolumeRef"^^xsd:string 91 + [ sp:varName "productionFlow"^^xsd:string
64 ] 92 ]
65 ] [ sp:object 93 ] [ sp:object
66 - [ sp:varName "contextFacilityRef"^^xsd:string 94 + [ sp:varName "productionFlowToDate"^^xsd:string
67 ] ; 95 ] ;
68 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 96 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
69 sp:subject 97 sp:subject
70 - [ sp:varName "contextFacility"^^xsd:string 98 + [ sp:varName "productionFlow"^^xsd:string
71 ] 99 ]
72 - ]) 100 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlowToDate> ;
73 - ] ;
74 - spin:rule
75 - [ rdf:type sp:Construct ;
76 - rdfs:comment "STEP 20010 Create the ProductVolumeReport; the period ProductionFacility and the ProductionFacilityToDate ."^^xsd:string ;
77 - sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductVolumeReport> ;
78 - sp:predicate rdf:type ;
79 - sp:subject _:b1
80 - ] [ sp:object
81 - [ sp:varName "productionReport"^^xsd:string
82 - ] ;
83 - sp:predicate <http://www.reportinghub.no/ep/schema/core#partOf> ;
84 - sp:subject _:b1
85 - ] [ sp:object
86 - [ sp:varName "name"^^xsd:string
87 - ] ;
88 - sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
89 - sp:subject _:b1
90 - ] [ sp:object
91 - [ sp:varName "reportPeriodType"^^xsd:string
92 - ] ;
93 sp:predicate rdf:type ; 101 sp:predicate rdf:type ;
94 - sp:subject _:b1 102 + sp:subject
103 + [ sp:varName "productionFlowToDate"^^xsd:string
104 + ]
95 ] [ sp:object 105 ] [ sp:object
96 [ sp:varName "productVolumeRef"^^xsd:string 106 [ sp:varName "productVolumeRef"^^xsd:string
97 ] ; 107 ] ;
98 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 108 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
99 - sp:subject _:b1 109 + sp:subject
100 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ; 110 + [ sp:varName "productionInventory"^^xsd:string
111 + ]
112 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventory> ;
101 sp:predicate rdf:type ; 113 sp:predicate rdf:type ;
102 - sp:subject _:b2 114 + sp:subject
115 + [ sp:varName "productionInventory"^^xsd:string
116 + ]
103 ] [ sp:object 117 ] [ sp:object
104 - [ sp:varName "productVolumeRef"^^xsd:string 118 + [ sp:varName "productionInventoryToDate"^^xsd:string
105 ] ; 119 ] ;
106 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
107 - sp:subject _:b2
108 - ] [ sp:object _:b3 ;
109 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 120 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
110 - sp:subject _:b2 121 + sp:subject
111 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ; 122 + [ sp:varName "productionInventory"^^xsd:string
123 + ]
124 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventoryToDate> ;
112 sp:predicate rdf:type ; 125 sp:predicate rdf:type ;
113 - sp:subject _:b3
114 - ] [ sp:object
115 - [] ;
116 - sp:predicate <http://www.reportinghub.no/ep/schema/flow#facilityContainsFlow> ;
117 - sp:subject _:b2
118 - ] [ sp:object
119 - [] ;
120 - sp:predicate <http://www.reportinghub.no/ep/schema/flow#facilityContainsFlow> ;
121 - sp:subject _:b3
122 - ] [ sp:object
123 - [ sp:varName "title"^^xsd:string
124 - ] ;
125 - sp:predicate <http://purl.org/dc/elements/1.1/title> ;
126 - sp:subject _:b1
127 - ]) ;
128 - sp:where ([ sp:object spin:_this ;
129 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
130 sp:subject 126 sp:subject
131 - [ sp:varName "productionReport"^^xsd:string 127 + [ sp:varName "productionInventoryToDate"^^xsd:string
132 ] 128 ]
133 ] [ sp:object 129 ] [ sp:object
134 [ sp:varName "productVolumeRef"^^xsd:string 130 [ sp:varName "productVolumeRef"^^xsd:string
135 ] ; 131 ] ;
136 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 132 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
137 - sp:subject spin:_this
138 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
139 - sp:predicate rdf:type ;
140 sp:subject 133 sp:subject
141 - [ sp:varName "productVolumeRef"^^xsd:string 134 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
142 ] 135 ]
143 - ] [ sp:object 136 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
144 - [ sp:varName "nameRef"^^xsd:string 137 + sp:predicate rdf:type ;
145 - ] ;
146 - sp:predicate <http://www.epim.no/schemas/mprml/1#nameRef> ;
147 sp:subject 138 sp:subject
148 - [ sp:varName "productVolumeRef"^^xsd:string 139 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
149 ] 140 ]
150 ] [ sp:object 141 ] [ sp:object
151 - [ sp:varName "name"^^xsd:string 142 + [ sp:varName "productionFacilityToDate"^^xsd:string
152 ] ; 143 ] ;
153 - sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 144 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
154 sp:subject 145 sp:subject
155 - [ sp:varName "nameRef"^^xsd:string 146 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
156 ] 147 ]
157 - ] [ rdf:type sp:Optional ; 148 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ;
158 - sp:elements ([ sp:object 149 + sp:predicate rdf:type ;
159 - [ sp:varName "periodKindRef"^^xsd:string 150 + sp:subject
160 - ] ; 151 + [ sp:varName "productionFacilityToDate"^^xsd:string
161 - sp:predicate <http://www.epim.no/schemas/mprml/1#periodKindRef> ;
162 - sp:subject
163 - [ sp:varName "productVolumeRef"^^xsd:string
164 - ]
165 - ])
166 - ] [ rdf:type sp:Optional ;
167 - sp:elements ([ sp:object
168 - [ sp:varName "titleRef"^^xsd:string
169 - ] ;
170 - sp:predicate <http://www.epim.no/schemas/mprml/1#titleRef> ;
171 - sp:subject
172 - [ sp:varName "productVolumeRef"^^xsd:string
173 - ]
174 - ] [ sp:object
175 - [ sp:varName "title"^^xsd:string
176 - ] ;
177 - sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
178 - sp:subject
179 - [ sp:varName "titleRef"^^xsd:string
180 - ]
181 - ])
182 - ] [ rdf:type sp:Bind ;
183 - sp:expression
184 - [ rdf:type ep-mpr-spin-lib:selectReportPeriodType ;
185 - sp:arg1 [ sp:varName "periodKindRef"^^xsd:string
186 - ]
187 - ] ;
188 - sp:variable
189 - [ sp:varName "reportPeriodType"^^xsd:string
190 ] 152 ]
191 ]) 153 ])
192 ] ; 154 ] ;
193 spin:rule 155 spin:rule
194 [ rdf:type sp:Construct ; 156 [ rdf:type sp:Construct ;
195 - rdfs:comment "STEP 20020 Add the report kind ."^^xsd:string ; 157 + rdfs:comment """STEP 20060 Set the facility operator
196 - sp:templates ([ sp:object 158 +role is ignored, because it is implicitly \"operator\""""^^xsd:string ;
197 - [ sp:varName "reportKind"^^xsd:string 159 + sp:templates ([ sp:object _:b1 ;
198 - ] ; 160 + sp:predicate <http://www.reportinghub.no/ep/schema/facility#facilityOperator> ;
199 - sp:predicate rdf:type ;
200 sp:subject 161 sp:subject
201 - [ sp:varName "productVolumeReport"^^xsd:string 162 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
202 ] 163 ]
203 - ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReportKind> ; 164 + ] [ sp:object <http://www.reportinghub.no/ep/schema/organization#Organization> ;
204 sp:predicate rdf:type ; 165 sp:predicate rdf:type ;
205 - sp:subject 166 + sp:subject _:b1
206 - [ sp:varName "reportKind"^^xsd:string
207 - ]
208 - ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
209 - sp:predicate rdfs:subClassOf ;
210 - sp:subject
211 - [ sp:varName "reportKind"^^xsd:string
212 - ]
213 ] [ sp:object 167 ] [ sp:object
214 - [ sp:varName "kind"^^xsd:string 168 + [ sp:varName "operator"^^xsd:string
215 ] ; 169 ] ;
216 - sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ; 170 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
217 - sp:subject 171 + sp:subject _:b1
218 - [ sp:varName "reportKind"^^xsd:string
219 - ]
220 ]) ; 172 ]) ;
221 sp:where ([ sp:object 173 sp:where ([ sp:object
222 [ sp:varName "productVolumeRef"^^xsd:string 174 [ sp:varName "productVolumeRef"^^xsd:string
223 ] ; 175 ] ;
224 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 176 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
225 sp:subject spin:_this 177 sp:subject spin:_this
226 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
227 - sp:predicate rdf:type ;
228 - sp:subject
229 - [ sp:varName "productVolumeRef"^^xsd:string
230 - ]
231 ] [ sp:object 178 ] [ sp:object
232 [ sp:varName "productVolumeRef"^^xsd:string 179 [ sp:varName "productVolumeRef"^^xsd:string
233 ] ; 180 ] ;
234 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 181 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
235 sp:subject 182 sp:subject
236 - [ sp:varName "productVolumeReport"^^xsd:string 183 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
237 ] 184 ]
238 - ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductVolumeReport> ; 185 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
239 sp:predicate rdf:type ; 186 sp:predicate rdf:type ;
240 sp:subject 187 sp:subject
241 - [ sp:varName "productVolumeReport"^^xsd:string 188 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
242 ] 189 ]
243 - ] [ sp:object 190 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
244 - [ sp:varName "nameRef"^^xsd:string 191 + sp:predicate rdf:type ;
245 - ] ;
246 - sp:predicate <http://www.epim.no/schemas/mprml/1#nameRef> ;
247 sp:subject 192 sp:subject
248 [ sp:varName "productVolumeRef"^^xsd:string 193 [ sp:varName "productVolumeRef"^^xsd:string
249 ] 194 ]
250 ] [ sp:object 195 ] [ sp:object
251 - [ sp:varName "name"^^xsd:string 196 + [ sp:varName "operatorRef"^^xsd:string
252 ] ; 197 ] ;
253 - sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 198 + sp:predicate <http://www.epim.no/schemas/mprml/1#operatorRef> ;
254 sp:subject 199 sp:subject
255 - [ sp:varName "nameRef"^^xsd:string 200 + [ sp:varName "productVolumeRef"^^xsd:string
256 ] 201 ]
257 ] [ sp:object 202 ] [ sp:object
258 - [ sp:varName "kind"^^xsd:string 203 + [ sp:varName "operatorRef"^^xsd:string
259 ] ; 204 ] ;
260 - sp:predicate <http://www.epim.no/schemas/mprml/1#kind> ; 205 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
261 sp:subject 206 sp:subject
262 - [ sp:varName "productVolumeRef"^^xsd:string 207 + [ sp:varName "operator"^^xsd:string
263 - ]
264 - ] [ rdf:type sp:Bind ;
265 - sp:expression
266 - [ rdf:type ep-dpr-spin-lib:buildProductionReportKindURI ;
267 - sp:arg1 [ sp:varName "kind"^^xsd:string
268 - ]
269 - ] ;
270 - sp:variable
271 - [ sp:varName "reportKind"^^xsd:string
272 ] 208 ]
273 ]) 209 ])
274 ] ; 210 ] ;
275 spin:rule 211 spin:rule
276 [ rdf:type sp:Construct ; 212 [ rdf:type sp:Construct ;
277 rdfs:comment "STEP 20011 Create the period ProductionFlow and the ProductionFlowToDate - if necessary ."^^xsd:string ; 213 rdfs:comment "STEP 20011 Create the period ProductionFlow and the ProductionFlowToDate - if necessary ."^^xsd:string ;
278 - sp:templates ([ sp:object _:b4 ; 214 + sp:templates ([ sp:object _:b2 ;
279 sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ; 215 sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ;
280 sp:subject 216 sp:subject
281 [ sp:varName "productVolumeReport"^^xsd:string 217 [ sp:varName "productVolumeReport"^^xsd:string
282 ] 218 ]
283 ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlow> ; 219 ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlow> ;
284 sp:predicate rdf:type ; 220 sp:predicate rdf:type ;
285 - sp:subject _:b4 221 + sp:subject _:b2
286 ] [ sp:object 222 ] [ sp:object
287 [ sp:varName "productVolumeRef"^^xsd:string 223 [ sp:varName "productVolumeRef"^^xsd:string
288 ] ; 224 ] ;
289 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 225 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
290 - sp:subject _:b4 226 + sp:subject _:b2
291 - ] [ sp:object _:b5 ; 227 + ] [ sp:object _:b3 ;
292 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 228 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
293 - sp:subject _:b4 229 + sp:subject _:b2
294 ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlowToDate> ; 230 ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlowToDate> ;
295 sp:predicate rdf:type ; 231 sp:predicate rdf:type ;
296 - sp:subject _:b5 232 + sp:subject _:b3
297 - ] [ sp:object _:b4 ; 233 + ] [ sp:object _:b2 ;
298 sp:predicate <http://www.reportinghub.no/ep/schema/flow#facilityContainsFlow> ; 234 sp:predicate <http://www.reportinghub.no/ep/schema/flow#facilityContainsFlow> ;
299 sp:subject 235 sp:subject
300 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 236 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
301 ] 237 ]
302 - ] [ sp:object _:b5 ; 238 + ] [ sp:object _:b3 ;
303 sp:predicate <http://www.reportinghub.no/ep/schema/flow#facilityContainsFlow> ; 239 sp:predicate <http://www.reportinghub.no/ep/schema/flow#facilityContainsFlow> ;
304 sp:subject 240 sp:subject
305 [ sp:varName "productionFacilityToDate"^^xsd:string 241 [ sp:varName "productionFacilityToDate"^^xsd:string
...@@ -310,6 +246,11 @@ ...@@ -310,6 +246,11 @@
310 sp:subject 246 sp:subject
311 [ sp:varName "productionReport"^^xsd:string 247 [ sp:varName "productionReport"^^xsd:string
312 ] 248 ]
249 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
250 + sp:predicate rdf:type ;
251 + sp:subject
252 + [ sp:varName "productionReport"^^xsd:string
253 + ]
313 ] [ sp:object 254 ] [ sp:object
314 [ sp:varName "productVolumeRef"^^xsd:string 255 [ sp:varName "productVolumeRef"^^xsd:string
315 ] ; 256 ] ;
...@@ -360,170 +301,239 @@ ...@@ -360,170 +301,239 @@
360 ] ; 301 ] ;
361 spin:rule 302 spin:rule
362 [ rdf:type sp:Construct ; 303 [ rdf:type sp:Construct ;
363 - rdfs:comment "STEP 20012 Create the period ProductionInventory and the ProductionInventoryToDate - if necessary ."^^xsd:string ; 304 + rdfs:comment "STEP 20050 Set the context facility - installation is always specified"^^xsd:string ;
364 - sp:templates ([ sp:object _:b6 ; 305 + sp:templates ([ sp:object
365 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ; 306 + [ sp:varName "contextFacility"^^xsd:string
307 + ] ;
308 + sp:predicate <http://www.reportinghub.no/ep/schema/geography#locatedWithin> ;
366 sp:subject 309 sp:subject
367 - [ sp:varName "productVolumeReport"^^xsd:string 310 + [ sp:varName "productionFacility"^^xsd:string
368 ] 311 ]
369 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventory> ; 312 + ]) ;
370 - sp:predicate rdf:type ; 313 + sp:where ([ sp:object
371 - sp:subject _:b6
372 - ] [ sp:object
373 [ sp:varName "productVolumeRef"^^xsd:string 314 [ sp:varName "productVolumeRef"^^xsd:string
374 ] ; 315 ] ;
375 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 316 + sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
376 - sp:subject _:b6 317 + sp:subject spin:_this
377 - ] [ sp:object _:b7 ; 318 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
378 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
379 - sp:subject _:b6
380 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventoryToDate> ;
381 sp:predicate rdf:type ; 319 sp:predicate rdf:type ;
382 - sp:subject _:b7
383 - ] [ sp:object _:b6 ;
384 - sp:predicate <http://www.reportinghub.no/ep/schema/core#hasSpatialPart> ;
385 sp:subject 320 sp:subject
386 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 321 + [ sp:varName "productVolumeRef"^^xsd:string
387 ] 322 ]
388 - ] [ sp:object _:b7 ; 323 + ] [ sp:object
389 - sp:predicate <http://www.reportinghub.no/ep/schema/core#hasSpatialPart> ; 324 + [ sp:varName "installationRef"^^xsd:string
325 + ] ;
326 + sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
390 sp:subject 327 sp:subject
391 - [ sp:varName "productionFacilityToDate"^^xsd:string 328 + [ sp:varName "productVolumeRef"^^xsd:string
392 ] 329 ]
393 ] [ sp:object 330 ] [ sp:object
394 - [ sp:varName "facilityRef"^^xsd:string 331 + [ sp:varName "installationRef"^^xsd:string
395 ] ; 332 ] ;
396 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 333 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
397 - sp:subject _:b6 334 + sp:subject
335 + [ sp:varName "productionFacility"^^xsd:string
336 + ]
398 ] [ sp:object 337 ] [ sp:object
399 - [ sp:varName "flowRef"^^xsd:string 338 + [ sp:varName "contextFacilityRef"^^xsd:string
400 ] ; 339 ] ;
401 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 340 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ;
402 - sp:subject _:b6 341 + sp:subject
342 + [ sp:varName "productVolumeRef"^^xsd:string
343 + ]
403 ] [ sp:object 344 ] [ sp:object
404 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 345 + [ sp:varName "contextFacilityRef"^^xsd:string
405 ] ; 346 ] ;
406 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 347 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
407 - sp:subject _:b6
408 - ]) ;
409 - sp:where ([ sp:object spin:_this ;
410 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
411 sp:subject 348 sp:subject
412 - [ sp:varName "productionReport"^^xsd:string 349 + [ sp:varName "contextFacility"^^xsd:string
413 ] 350 ]
414 - ] [ sp:object 351 + ])
415 - [ sp:varName "productVolumeRef"^^xsd:string 352 + ] ;
353 + spin:rule
354 + [ rdf:type sp:Construct ;
355 + rdfs:comment "STEP 20033 Inherit end dates from the report context if necessary"^^xsd:string ;
356 + sp:templates ([ sp:object
357 + [ sp:varName "dateEnd"^^xsd:string
416 ] ; 358 ] ;
417 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 359 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
418 - sp:subject spin:_this
419 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
420 - sp:predicate rdf:type ;
421 sp:subject 360 sp:subject
422 - [ sp:varName "productVolumeRef"^^xsd:string 361 + [ sp:varName "productionFlow"^^xsd:string
423 ] 362 ]
424 ] [ sp:object 363 ] [ sp:object
425 - [ sp:varName "productVolumeRef"^^xsd:string 364 + [ sp:varName "dateEnd"^^xsd:string
426 ] ; 365 ] ;
427 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 366 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
428 sp:subject 367 sp:subject
429 - [ sp:varName "productVolumeReport"^^xsd:string 368 + [ sp:varName "productionFlowToDate"^^xsd:string
430 ] 369 ]
431 - ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductVolumeReport> ; 370 + ] [ sp:object
432 - sp:predicate rdf:type ; 371 + [ sp:varName "dateEnd"^^xsd:string
372 + ] ;
373 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
433 sp:subject 374 sp:subject
434 - [ sp:varName "productVolumeReport"^^xsd:string 375 + [ sp:varName "productionInventory"^^xsd:string
435 ] 376 ]
436 ] [ sp:object 377 ] [ sp:object
437 - [ sp:varName "productVolumeRef"^^xsd:string 378 + [ sp:varName "dateEnd"^^xsd:string
438 ] ; 379 ] ;
439 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 380 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
440 sp:subject 381 sp:subject
441 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 382 + [ sp:varName "productionInventoryToDate"^^xsd:string
442 ] 383 ]
443 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ; 384 + ] [ sp:object
444 - sp:predicate rdf:type ; 385 + [ sp:varName "dateEnd"^^xsd:string
386 + ] ;
387 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
445 sp:subject 388 sp:subject
446 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 389 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
447 ] 390 ]
448 ] [ sp:object 391 ] [ sp:object
392 + [ sp:varName "dateEnd"^^xsd:string
393 + ] ;
394 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
395 + sp:subject
449 [ sp:varName "productionFacilityToDate"^^xsd:string 396 [ sp:varName "productionFacilityToDate"^^xsd:string
397 + ]
398 + ]) ;
399 + sp:where ([ sp:object
400 + [ sp:varName "productVolumeRef"^^xsd:string
450 ] ; 401 ] ;
451 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 402 + sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
403 + sp:subject spin:_this
404 + ] [ sp:object
405 + [ sp:varName "dateEnd"^^xsd:string
406 + ] ;
407 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalEnd> ;
408 + sp:subject spin:_this
409 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
410 + sp:predicate rdf:type ;
452 sp:subject 411 sp:subject
453 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 412 + [ sp:varName "productVolumeRef"^^xsd:string
454 ] 413 ]
455 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ; 414 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
456 sp:predicate rdf:type ; 415 sp:predicate rdf:type ;
457 sp:subject 416 sp:subject
458 - [ sp:varName "productionFacilityToDate"^^xsd:string 417 + [ sp:varName "productVolumeRef"^^xsd:string
459 ] 418 ]
460 - ]) 419 + ] [ rdf:type sp:NotExists ;
461 - ] ; 420 + sp:elements ([ sp:object
462 - spin:rule 421 + [ sp:varName "dateEndx"^^xsd:string
463 - [ rdf:type sp:Construct ; 422 + ] ;
464 - rdfs:comment "STEP 20030 Record the start and end date-times"^^xsd:string ; 423 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
465 - sp:templates ([ sp:object 424 + sp:subject
466 - [ sp:varName "dTimStart"^^xsd:string 425 + [ sp:varName "productVolumeRef"^^xsd:string
426 + ]
427 + ])
428 + ] [ rdf:type sp:NotExists ;
429 + sp:elements ([ sp:object
430 + [ sp:varName "dTimEndx"^^xsd:string
431 + ] ;
432 + sp:predicate <http://www.epim.no/schemas/mprml/1#dTimEnd> ;
433 + sp:subject
434 + [ sp:varName "productVolumeRef"^^xsd:string
435 + ]
436 + ])
437 + ] [ sp:object
438 + [ sp:varName "productVolumeRef"^^xsd:string
467 ] ; 439 ] ;
468 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ; 440 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
469 sp:subject 441 sp:subject
470 [ sp:varName "productionFlow"^^xsd:string 442 [ sp:varName "productionFlow"^^xsd:string
471 ] 443 ]
472 - ] [ sp:object 444 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlow> ;
473 - [ sp:varName "dTimEnd"^^xsd:string 445 + sp:predicate rdf:type ;
474 - ] ;
475 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
476 sp:subject 446 sp:subject
477 [ sp:varName "productionFlow"^^xsd:string 447 [ sp:varName "productionFlow"^^xsd:string
478 ] 448 ]
479 ] [ sp:object 449 ] [ sp:object
480 - [ sp:varName "dTimEnd"^^xsd:string 450 + [ sp:varName "productionFlowToDate"^^xsd:string
481 ] ; 451 ] ;
482 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 452 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
453 + sp:subject
454 + [ sp:varName "productionFlow"^^xsd:string
455 + ]
456 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlowToDate> ;
457 + sp:predicate rdf:type ;
483 sp:subject 458 sp:subject
484 [ sp:varName "productionFlowToDate"^^xsd:string 459 [ sp:varName "productionFlowToDate"^^xsd:string
485 ] 460 ]
486 ] [ sp:object 461 ] [ sp:object
487 - [ sp:varName "dTimStart"^^xsd:string 462 + [ sp:varName "productVolumeRef"^^xsd:string
488 ] ; 463 ] ;
489 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ; 464 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
490 sp:subject 465 sp:subject
491 [ sp:varName "productionInventory"^^xsd:string 466 [ sp:varName "productionInventory"^^xsd:string
492 ] 467 ]
493 - ] [ sp:object 468 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventory> ;
494 - [ sp:varName "dTimEnd"^^xsd:string 469 + sp:predicate rdf:type ;
495 - ] ;
496 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
497 sp:subject 470 sp:subject
498 [ sp:varName "productionInventory"^^xsd:string 471 [ sp:varName "productionInventory"^^xsd:string
499 ] 472 ]
500 ] [ sp:object 473 ] [ sp:object
501 - [ sp:varName "dTimEnd"^^xsd:string 474 + [ sp:varName "productionInventoryToDate"^^xsd:string
502 ] ; 475 ] ;
503 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 476 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
477 + sp:subject
478 + [ sp:varName "productionInventory"^^xsd:string
479 + ]
480 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventoryToDate> ;
481 + sp:predicate rdf:type ;
504 sp:subject 482 sp:subject
505 [ sp:varName "productionInventoryToDate"^^xsd:string 483 [ sp:varName "productionInventoryToDate"^^xsd:string
506 ] 484 ]
507 ] [ sp:object 485 ] [ sp:object
508 - [ sp:varName "dTimStart"^^xsd:string 486 + [ sp:varName "productVolumeRef"^^xsd:string
509 ] ; 487 ] ;
510 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ; 488 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
489 + sp:subject
490 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
491 + ]
492 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
493 + sp:predicate rdf:type ;
511 sp:subject 494 sp:subject
512 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 495 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
513 ] 496 ]
514 ] [ sp:object 497 ] [ sp:object
515 - [ sp:varName "dTimEnd"^^xsd:string 498 + [ sp:varName "productionFacilityToDate"^^xsd:string
516 ] ; 499 ] ;
517 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 500 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
518 sp:subject 501 sp:subject
519 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 502 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
520 ] 503 ]
504 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ;
505 + sp:predicate rdf:type ;
506 + sp:subject
507 + [ sp:varName "productionFacilityToDate"^^xsd:string
508 + ]
509 + ])
510 + ] ;
511 + spin:rule
512 + [ rdf:type sp:Construct ;
513 + rdfs:comment "STEP 20020 Add the report kind ."^^xsd:string ;
514 + sp:templates ([ sp:object
515 + [ sp:varName "reportKind"^^xsd:string
516 + ] ;
517 + sp:predicate rdf:type ;
518 + sp:subject
519 + [ sp:varName "productVolumeReport"^^xsd:string
520 + ]
521 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReportKind> ;
522 + sp:predicate rdf:type ;
523 + sp:subject
524 + [ sp:varName "reportKind"^^xsd:string
525 + ]
526 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
527 + sp:predicate rdfs:subClassOf ;
528 + sp:subject
529 + [ sp:varName "reportKind"^^xsd:string
530 + ]
521 ] [ sp:object 531 ] [ sp:object
522 - [ sp:varName "dTimEnd"^^xsd:string 532 + [ sp:varName "kind"^^xsd:string
523 ] ; 533 ] ;
524 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 534 + sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
525 sp:subject 535 sp:subject
526 - [ sp:varName "productionFacilityToDate"^^xsd:string 536 + [ sp:varName "reportKind"^^xsd:string
527 ] 537 ]
528 ]) ; 538 ]) ;
529 sp:where ([ sp:object 539 sp:where ([ sp:object
...@@ -534,69 +544,100 @@ ...@@ -534,69 +544,100 @@
534 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ; 544 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
535 sp:predicate rdf:type ; 545 sp:predicate rdf:type ;
536 sp:subject 546 sp:subject
537 - [ sp:varName "productVolumeRef"^^xsd:string 547 + [ sp:varName "productVolumeRef"^^xsd:string
548 + ]
549 + ] [ sp:object
550 + [ sp:varName "productVolumeRef"^^xsd:string
551 + ] ;
552 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
553 + sp:subject
554 + [ sp:varName "productVolumeReport"^^xsd:string
555 + ]
556 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductVolumeReport> ;
557 + sp:predicate rdf:type ;
558 + sp:subject
559 + [ sp:varName "productVolumeReport"^^xsd:string
538 ] 560 ]
539 ] [ sp:object 561 ] [ sp:object
540 - [ sp:varName "dTimStart"^^xsd:string 562 + [ sp:varName "nameRef"^^xsd:string
541 ] ; 563 ] ;
542 - sp:predicate <http://www.epim.no/schemas/mprml/1#dTimStart> ; 564 + sp:predicate <http://www.epim.no/schemas/mprml/1#nameRef> ;
543 sp:subject 565 sp:subject
544 [ sp:varName "productVolumeRef"^^xsd:string 566 [ sp:varName "productVolumeRef"^^xsd:string
545 ] 567 ]
546 ] [ sp:object 568 ] [ sp:object
547 - [ sp:varName "dTimEnd"^^xsd:string 569 + [ sp:varName "name"^^xsd:string
548 ] ; 570 ] ;
549 - sp:predicate <http://www.epim.no/schemas/mprml/1#dTimEnd> ; 571 + sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
550 sp:subject 572 sp:subject
551 - [ sp:varName "productVolumeRef"^^xsd:string 573 + [ sp:varName "nameRef"^^xsd:string
552 ] 574 ]
553 ] [ sp:object 575 ] [ sp:object
554 - [ sp:varName "productVolumeRef"^^xsd:string 576 + [ sp:varName "kind"^^xsd:string
555 ] ; 577 ] ;
556 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 578 + sp:predicate <http://www.epim.no/schemas/mprml/1#kind> ;
557 sp:subject 579 sp:subject
558 - [ sp:varName "productionFlow"^^xsd:string 580 + [ sp:varName "productVolumeRef"^^xsd:string
559 ] 581 ]
560 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlow> ; 582 + ] [ rdf:type sp:Bind ;
561 - sp:predicate rdf:type ; 583 + sp:expression
562 - sp:subject 584 + [ rdf:type ep-dpr-spin-lib:buildProductionReportKindURI ;
563 - [ sp:varName "productionFlow"^^xsd:string 585 + sp:arg1 [ sp:varName "kind"^^xsd:string
586 + ]
587 + ] ;
588 + sp:variable
589 + [ sp:varName "reportKind"^^xsd:string
564 ] 590 ]
565 - ] [ sp:object 591 + ])
566 - [ sp:varName "productionFlowToDate"^^xsd:string 592 + ] ;
593 + spin:rule
594 + [ rdf:type sp:Construct ;
595 + rdfs:comment "STEP 20040 Set the production facility - supplied"^^xsd:string ;
596 + sp:templates ([ sp:object
597 + [ sp:varName "productionFacility"^^xsd:string
567 ] ; 598 ] ;
568 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 599 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
569 sp:subject 600 sp:subject
570 - [ sp:varName "productionFlow"^^xsd:string 601 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
571 ] 602 ]
572 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlowToDate> ; 603 + ] [ sp:object
573 - sp:predicate rdf:type ; 604 + [ sp:varName "productionFacility"^^xsd:string
605 + ] ;
606 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
574 sp:subject 607 sp:subject
575 - [ sp:varName "productionFlowToDate"^^xsd:string 608 + [ sp:varName "productionFacilityToDate"^^xsd:string
576 ] 609 ]
577 ] [ sp:object 610 ] [ sp:object
578 - [ sp:varName "productVolumeRef"^^xsd:string 611 + [ sp:varName "normalizedProductionFacilityName"^^xsd:string
579 ] ; 612 ] ;
580 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 613 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
581 sp:subject 614 sp:subject
582 - [ sp:varName "productionInventory"^^xsd:string 615 + [ sp:varName "productVolumeRef"^^xsd:string
583 ] 616 ]
584 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventory> ; 617 + ]) ;
618 + sp:where ([ sp:object
619 + [ sp:varName "productVolumeRef"^^xsd:string
620 + ] ;
621 + sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
622 + sp:subject spin:_this
623 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
585 sp:predicate rdf:type ; 624 sp:predicate rdf:type ;
586 sp:subject 625 sp:subject
587 - [ sp:varName "productionInventory"^^xsd:string 626 + [ sp:varName "productVolumeRef"^^xsd:string
588 ] 627 ]
589 ] [ sp:object 628 ] [ sp:object
590 - [ sp:varName "productionInventoryToDate"^^xsd:string 629 + [ sp:varName "installationRef"^^xsd:string
591 ] ; 630 ] ;
592 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 631 + sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
593 sp:subject 632 sp:subject
594 - [ sp:varName "productionInventory"^^xsd:string 633 + [ sp:varName "productVolumeRef"^^xsd:string
595 ] 634 ]
596 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventoryToDate> ; 635 + ] [ sp:object
597 - sp:predicate rdf:type ; 636 + [ sp:varName "installationRef"^^xsd:string
637 + ] ;
638 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
598 sp:subject 639 sp:subject
599 - [ sp:varName "productionInventoryToDate"^^xsd:string 640 + [ sp:varName "productionFacility"^^xsd:string
600 ] 641 ]
601 ] [ sp:object 642 ] [ sp:object
602 [ sp:varName "productVolumeRef"^^xsd:string 643 [ sp:varName "productVolumeRef"^^xsd:string
...@@ -622,201 +663,195 @@ ...@@ -622,201 +663,195 @@
622 sp:subject 663 sp:subject
623 [ sp:varName "productionFacilityToDate"^^xsd:string 664 [ sp:varName "productionFacilityToDate"^^xsd:string
624 ] 665 ]
666 + ] [ rdf:type sp:Bind ;
667 + sp:expression
668 + [ rdf:type spl:object ;
669 + sp:arg1 [ sp:varName "installationRef"^^xsd:string
670 + ] ;
671 + sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText>
672 + ] ;
673 + sp:variable
674 + [ sp:varName "normalizedProductionFacilityName"^^xsd:string
675 + ]
625 ]) 676 ])
626 ] ; 677 ] ;
627 spin:rule 678 spin:rule
628 [ rdf:type sp:Construct ; 679 [ rdf:type sp:Construct ;
629 - rdfs:comment "STEP 20032 Inherit start dates from the report context if necessary"^^xsd:string ; 680 + rdfs:comment "STEP 20010 Create the ProductVolumeReport; the period ProductionFacility and the ProductionFacilityToDate ."^^xsd:string ;
630 - sp:templates ([ sp:object 681 + sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductVolumeReport> ;
631 - [ sp:varName "dateStart"^^xsd:string 682 + sp:predicate rdf:type ;
632 - ] ; 683 + sp:subject _:b4
633 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
634 - sp:subject
635 - [ sp:varName "productionFlow"^^xsd:string
636 - ]
637 ] [ sp:object 684 ] [ sp:object
638 - [ sp:varName "dateStart"^^xsd:string 685 + [ sp:varName "productionReport"^^xsd:string
639 ] ; 686 ] ;
640 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ; 687 + sp:predicate <http://www.reportinghub.no/ep/schema/core#partOf> ;
641 - sp:subject 688 + sp:subject _:b4
642 - [ sp:varName "productionInventory"^^xsd:string
643 - ]
644 ] [ sp:object 689 ] [ sp:object
645 - [ sp:varName "dateStart"^^xsd:string 690 + [ sp:varName "name"^^xsd:string
646 - ] ;
647 - sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
648 - sp:subject
649 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
650 - ]
651 - ]) ;
652 - sp:where ([ sp:object
653 - [ sp:varName "productVolumeRef"^^xsd:string
654 ] ; 691 ] ;
655 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 692 + sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
656 - sp:subject spin:_this 693 + sp:subject _:b4
657 ] [ sp:object 694 ] [ sp:object
658 - [ sp:varName "dateStart"^^xsd:string 695 + [ sp:varName "reportPeriodType"^^xsd:string
659 ] ; 696 ] ;
660 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ;
661 - sp:subject spin:_this
662 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
663 sp:predicate rdf:type ; 697 sp:predicate rdf:type ;
664 - sp:subject 698 + sp:subject _:b4
665 - [ sp:varName "productVolumeRef"^^xsd:string
666 - ]
667 - ] [ rdf:type sp:NotExists ;
668 - sp:elements ([ sp:object
669 - [ sp:varName "dateStartx"^^xsd:string
670 - ] ;
671 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
672 - sp:subject
673 - [ sp:varName "productVolumeRef"^^xsd:string
674 - ]
675 - ])
676 - ] [ rdf:type sp:NotExists ;
677 - sp:elements ([ sp:object
678 - [ sp:varName "dTimStartx"^^xsd:string
679 - ] ;
680 - sp:predicate <http://www.epim.no/schemas/mprml/1#dTimStart> ;
681 - sp:subject
682 - [ sp:varName "productVolumeRef"^^xsd:string
683 - ]
684 - ])
685 ] [ sp:object 699 ] [ sp:object
686 [ sp:varName "productVolumeRef"^^xsd:string 700 [ sp:varName "productVolumeRef"^^xsd:string
687 ] ; 701 ] ;
688 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 702 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
689 - sp:subject 703 + sp:subject _:b4
690 - [ sp:varName "productionFlow"^^xsd:string 704 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
691 - ]
692 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlow> ;
693 sp:predicate rdf:type ; 705 sp:predicate rdf:type ;
694 - sp:subject 706 + sp:subject _:b5
695 - [ sp:varName "productionFlow"^^xsd:string
696 - ]
697 ] [ sp:object 707 ] [ sp:object
698 - [ sp:varName "productionFlowToDate"^^xsd:string 708 + [ sp:varName "productVolumeRef"^^xsd:string
699 ] ; 709 ] ;
710 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
711 + sp:subject _:b5
712 + ] [ sp:object _:b6 ;
700 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 713 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
701 - sp:subject 714 + sp:subject _:b5
702 - [ sp:varName "productionFlow"^^xsd:string 715 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ;
703 - ]
704 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionFlowToDate> ;
705 sp:predicate rdf:type ; 716 sp:predicate rdf:type ;
706 - sp:subject 717 + sp:subject _:b6
707 - [ sp:varName "productionFlowToDate"^^xsd:string
708 - ]
709 ] [ sp:object 718 ] [ sp:object
710 - [ sp:varName "productVolumeRef"^^xsd:string 719 + [ sp:varName "title"^^xsd:string
711 ] ; 720 ] ;
721 + sp:predicate <http://purl.org/dc/elements/1.1/title> ;
722 + sp:subject _:b4
723 + ]) ;
724 + sp:where ([ sp:object spin:_this ;
712 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 725 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
713 sp:subject 726 sp:subject
714 - [ sp:varName "productionInventory"^^xsd:string 727 + [ sp:varName "productionReport"^^xsd:string
715 ] 728 ]
716 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventory> ; 729 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
717 sp:predicate rdf:type ; 730 sp:predicate rdf:type ;
718 sp:subject 731 sp:subject
719 - [ sp:varName "productionInventory"^^xsd:string 732 + [ sp:varName "productionReport"^^xsd:string
720 ] 733 ]
721 ] [ sp:object 734 ] [ sp:object
722 - [ sp:varName "productionInventoryToDate"^^xsd:string 735 + [ sp:varName "productVolumeRef"^^xsd:string
723 ] ; 736 ] ;
724 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 737 + sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
725 - sp:subject 738 + sp:subject spin:_this
726 - [ sp:varName "productionInventory"^^xsd:string 739 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
727 - ]
728 - ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventoryToDate> ;
729 sp:predicate rdf:type ; 740 sp:predicate rdf:type ;
730 sp:subject 741 sp:subject
731 - [ sp:varName "productionInventoryToDate"^^xsd:string 742 + [ sp:varName "productVolumeRef"^^xsd:string
732 ] 743 ]
733 ] [ sp:object 744 ] [ sp:object
734 - [ sp:varName "productVolumeRef"^^xsd:string 745 + [ sp:varName "nameRef"^^xsd:string
735 ] ; 746 ] ;
736 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 747 + sp:predicate <http://www.epim.no/schemas/mprml/1#nameRef> ;
737 - sp:subject
738 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
739 - ]
740 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
741 - sp:predicate rdf:type ;
742 sp:subject 748 sp:subject
743 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 749 + [ sp:varName "productVolumeRef"^^xsd:string
744 ] 750 ]
745 ] [ sp:object 751 ] [ sp:object
746 - [ sp:varName "productionFacilityToDate"^^xsd:string 752 + [ sp:varName "name"^^xsd:string
747 ] ; 753 ] ;
748 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 754 + sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
749 sp:subject 755 sp:subject
750 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 756 + [ sp:varName "nameRef"^^xsd:string
751 ] 757 ]
752 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ; 758 + ] [ rdf:type sp:Optional ;
753 - sp:predicate rdf:type ; 759 + sp:elements ([ sp:object
754 - sp:subject 760 + [ sp:varName "periodKindRef"^^xsd:string
755 - [ sp:varName "productionFacilityToDate"^^xsd:string 761 + ] ;
762 + sp:predicate <http://www.epim.no/schemas/mprml/1#periodKindRef> ;
763 + sp:subject
764 + [ sp:varName "productVolumeRef"^^xsd:string
765 + ]
766 + ])
767 + ] [ rdf:type sp:Optional ;
768 + sp:elements ([ sp:object
769 + [ sp:varName "titleRef"^^xsd:string
770 + ] ;
771 + sp:predicate <http://www.epim.no/schemas/mprml/1#titleRef> ;
772 + sp:subject
773 + [ sp:varName "productVolumeRef"^^xsd:string
774 + ]
775 + ] [ sp:object
776 + [ sp:varName "title"^^xsd:string
777 + ] ;
778 + sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
779 + sp:subject
780 + [ sp:varName "titleRef"^^xsd:string
781 + ]
782 + ])
783 + ] [ rdf:type sp:Bind ;
784 + sp:expression
785 + [ rdf:type ep-mpr-spin-lib:selectReportPeriodType ;
786 + sp:arg1 [ sp:varName "periodKindRef"^^xsd:string
787 + ]
788 + ] ;
789 + sp:variable
790 + [ sp:varName "reportPeriodType"^^xsd:string
756 ] 791 ]
757 ]) 792 ])
758 ] ; 793 ] ;
759 spin:rule 794 spin:rule
760 [ rdf:type sp:Construct ; 795 [ rdf:type sp:Construct ;
761 - rdfs:comment "STEP 20031 Record the start and end dates"^^xsd:string ; 796 + rdfs:comment "STEP 20030 Record the start and end date-times"^^xsd:string ;
762 sp:templates ([ sp:object 797 sp:templates ([ sp:object
763 - [ sp:varName "dateStart"^^xsd:string 798 + [ sp:varName "dTimStart"^^xsd:string
764 ] ; 799 ] ;
765 sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ; 800 sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
766 sp:subject 801 sp:subject
767 [ sp:varName "productionFlow"^^xsd:string 802 [ sp:varName "productionFlow"^^xsd:string
768 ] 803 ]
769 ] [ sp:object 804 ] [ sp:object
770 - [ sp:varName "dateEnd"^^xsd:string 805 + [ sp:varName "dTimEnd"^^xsd:string
771 ] ; 806 ] ;
772 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 807 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
773 sp:subject 808 sp:subject
774 [ sp:varName "productionFlow"^^xsd:string 809 [ sp:varName "productionFlow"^^xsd:string
775 ] 810 ]
776 ] [ sp:object 811 ] [ sp:object
777 - [ sp:varName "dateEnd"^^xsd:string 812 + [ sp:varName "dTimEnd"^^xsd:string
778 ] ; 813 ] ;
779 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 814 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
780 sp:subject 815 sp:subject
781 [ sp:varName "productionFlowToDate"^^xsd:string 816 [ sp:varName "productionFlowToDate"^^xsd:string
782 ] 817 ]
783 ] [ sp:object 818 ] [ sp:object
784 - [ sp:varName "dateStart"^^xsd:string 819 + [ sp:varName "dTimStart"^^xsd:string
785 ] ; 820 ] ;
786 sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ; 821 sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
787 sp:subject 822 sp:subject
788 [ sp:varName "productionInventory"^^xsd:string 823 [ sp:varName "productionInventory"^^xsd:string
789 ] 824 ]
790 ] [ sp:object 825 ] [ sp:object
791 - [ sp:varName "dateEnd"^^xsd:string 826 + [ sp:varName "dTimEnd"^^xsd:string
792 ] ; 827 ] ;
793 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 828 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
794 sp:subject 829 sp:subject
795 [ sp:varName "productionInventory"^^xsd:string 830 [ sp:varName "productionInventory"^^xsd:string
796 ] 831 ]
797 ] [ sp:object 832 ] [ sp:object
798 - [ sp:varName "dateEnd"^^xsd:string 833 + [ sp:varName "dTimEnd"^^xsd:string
799 ] ; 834 ] ;
800 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 835 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
801 sp:subject 836 sp:subject
802 [ sp:varName "productionInventoryToDate"^^xsd:string 837 [ sp:varName "productionInventoryToDate"^^xsd:string
803 ] 838 ]
804 ] [ sp:object 839 ] [ sp:object
805 - [ sp:varName "dateStart"^^xsd:string 840 + [ sp:varName "dTimStart"^^xsd:string
806 ] ; 841 ] ;
807 sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ; 842 sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
808 sp:subject 843 sp:subject
809 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 844 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
810 ] 845 ]
811 ] [ sp:object 846 ] [ sp:object
812 - [ sp:varName "dateEnd"^^xsd:string 847 + [ sp:varName "dTimEnd"^^xsd:string
813 ] ; 848 ] ;
814 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 849 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
815 sp:subject 850 sp:subject
816 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 851 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
817 ] 852 ]
818 ] [ sp:object 853 ] [ sp:object
819 - [ sp:varName "dateEnd"^^xsd:string 854 + [ sp:varName "dTimEnd"^^xsd:string
820 ] ; 855 ] ;
821 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 856 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
822 sp:subject 857 sp:subject
...@@ -834,16 +869,16 @@ ...@@ -834,16 +869,16 @@
834 [ sp:varName "productVolumeRef"^^xsd:string 869 [ sp:varName "productVolumeRef"^^xsd:string
835 ] 870 ]
836 ] [ sp:object 871 ] [ sp:object
837 - [ sp:varName "dateStart"^^xsd:string 872 + [ sp:varName "dTimStart"^^xsd:string
838 ] ; 873 ] ;
839 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ; 874 + sp:predicate <http://www.epim.no/schemas/mprml/1#dTimStart> ;
840 sp:subject 875 sp:subject
841 [ sp:varName "productVolumeRef"^^xsd:string 876 [ sp:varName "productVolumeRef"^^xsd:string
842 ] 877 ]
843 ] [ sp:object 878 ] [ sp:object
844 - [ sp:varName "dateEnd"^^xsd:string 879 + [ sp:varName "dTimEnd"^^xsd:string
845 ] ; 880 ] ;
846 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ; 881 + sp:predicate <http://www.epim.no/schemas/mprml/1#dTimEnd> ;
847 sp:subject 882 sp:subject
848 [ sp:varName "productVolumeRef"^^xsd:string 883 [ sp:varName "productVolumeRef"^^xsd:string
849 ] 884 ]
...@@ -923,7 +958,7 @@ ...@@ -923,7 +958,7 @@
923 ] ; 958 ] ;
924 spin:rule 959 spin:rule
925 [ rdf:type sp:Construct ; 960 [ rdf:type sp:Construct ;
926 - rdfs:comment "STEP 20040 Set the installation"^^xsd:string ; 961 + rdfs:comment "STEP 20041 Set the production facility - taken from context"^^xsd:string ;
927 sp:templates ([ sp:object 962 sp:templates ([ sp:object
928 [ sp:varName "productionFacility"^^xsd:string 963 [ sp:varName "productionFacility"^^xsd:string
929 ] ; 964 ] ;
...@@ -938,80 +973,48 @@ ...@@ -938,80 +973,48 @@
938 sp:subject 973 sp:subject
939 [ sp:varName "productionFacilityToDate"^^xsd:string 974 [ sp:varName "productionFacilityToDate"^^xsd:string
940 ] 975 ]
941 - ]) ;
942 - sp:where ([ sp:object
943 - [ sp:varName "productVolumeRef"^^xsd:string
944 - ] ;
945 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
946 - sp:subject spin:_this
947 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
948 - sp:predicate rdf:type ;
949 - sp:subject
950 - [ sp:varName "productVolumeRef"^^xsd:string
951 - ]
952 ] [ sp:object 976 ] [ sp:object
953 - [ sp:varName "installationRef"^^xsd:string 977 + [ sp:varName "normalizedProductionFacilityName"^^xsd:string
954 ] ; 978 ] ;
955 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ; 979 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
956 sp:subject 980 sp:subject
957 [ sp:varName "productVolumeRef"^^xsd:string 981 [ sp:varName "productVolumeRef"^^xsd:string
958 ] 982 ]
959 - ] [ sp:object 983 + ]) ;
960 - [ sp:varName "installationRef"^^xsd:string 984 + sp:where ([ sp:object spin:_this ;
961 - ] ;
962 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 985 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
963 sp:subject 986 sp:subject
964 [ sp:varName "productionFacility"^^xsd:string 987 [ sp:varName "productionFacility"^^xsd:string
965 ] 988 ]
966 - ] [ sp:object 989 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacility> ;
967 - [ sp:varName "productVolumeRef"^^xsd:string
968 - ] ;
969 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
970 - sp:subject
971 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
972 - ]
973 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
974 sp:predicate rdf:type ; 990 sp:predicate rdf:type ;
975 sp:subject 991 sp:subject
976 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 992 + [ sp:varName "productionFacility"^^xsd:string
977 ] 993 ]
978 ] [ sp:object 994 ] [ sp:object
979 - [ sp:varName "productionFacilityToDate"^^xsd:string 995 + [ sp:varName "normalizedProductionFacilityName"^^xsd:string
980 ] ; 996 ] ;
981 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 997 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
982 - sp:subject 998 + sp:subject spin:_this
983 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
984 - ]
985 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ;
986 - sp:predicate rdf:type ;
987 - sp:subject
988 - [ sp:varName "productionFacilityToDate"^^xsd:string
989 - ]
990 - ])
991 - ] ;
992 - spin:rule
993 - [ rdf:type sp:Construct ;
994 - rdfs:comment """STEP 20060 Set the facility operator
995 -role is ignored, because it is implicitly \"operator\""""^^xsd:string ;
996 - sp:templates ([ sp:object _:b8 ;
997 - sp:predicate <http://www.reportinghub.no/ep/schema/facility#facilityOperator> ;
998 - sp:subject
999 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1000 - ]
1001 - ] [ sp:object <http://www.reportinghub.no/ep/schema/organization#Organization> ;
1002 - sp:predicate rdf:type ;
1003 - sp:subject _:b8
1004 ] [ sp:object 999 ] [ sp:object
1005 - [ sp:varName "operator"^^xsd:string
1006 - ] ;
1007 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
1008 - sp:subject _:b8
1009 - ]) ;
1010 - sp:where ([ sp:object
1011 [ sp:varName "productVolumeRef"^^xsd:string 1000 [ sp:varName "productVolumeRef"^^xsd:string
1012 ] ; 1001 ] ;
1013 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 1002 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
1014 sp:subject spin:_this 1003 sp:subject spin:_this
1004 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
1005 + sp:predicate rdf:type ;
1006 + sp:subject
1007 + [ sp:varName "productVolumeRef"^^xsd:string
1008 + ]
1009 + ] [ rdf:type sp:NotExists ;
1010 + sp:elements ([ sp:object
1011 + [ sp:varName "installationRefx"^^xsd:string
1012 + ] ;
1013 + sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
1014 + sp:subject
1015 + [ sp:varName "productVolumeRef"^^xsd:string
1016 + ]
1017 + ])
1015 ] [ sp:object 1018 ] [ sp:object
1016 [ sp:varName "productVolumeRef"^^xsd:string 1019 [ sp:varName "productVolumeRef"^^xsd:string
1017 ] ; 1020 ] ;
...@@ -1024,31 +1027,31 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ; ...@@ -1024,31 +1027,31 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ;
1024 sp:subject 1027 sp:subject
1025 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 1028 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1026 ] 1029 ]
1027 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
1028 - sp:predicate rdf:type ;
1029 - sp:subject
1030 - [ sp:varName "productVolumeRef"^^xsd:string
1031 - ]
1032 ] [ sp:object 1030 ] [ sp:object
1033 - [ sp:varName "operatorRef"^^xsd:string 1031 + [ sp:varName "productionFacilityToDate"^^xsd:string
1034 ] ; 1032 ] ;
1035 - sp:predicate <http://www.epim.no/schemas/mprml/1#operatorRef> ; 1033 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
1036 sp:subject 1034 sp:subject
1037 - [ sp:varName "productVolumeRef"^^xsd:string 1035 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1038 ] 1036 ]
1039 - ] [ sp:object 1037 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ;
1040 - [ sp:varName "operatorRef"^^xsd:string 1038 + sp:predicate rdf:type ;
1041 - ] ;
1042 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
1043 sp:subject 1039 sp:subject
1044 - [ sp:varName "operator"^^xsd:string 1040 + [ sp:varName "productionFacilityToDate"^^xsd:string
1045 ] 1041 ]
1046 ]) 1042 ])
1047 ] ; 1043 ] ;
1048 spin:rule 1044 spin:rule
1049 [ rdf:type sp:Construct ; 1045 [ rdf:type sp:Construct ;
1050 - rdfs:comment "STEP 20033 Inherit end dates from the report context if necessary"^^xsd:string ; 1046 + rdfs:comment "STEP 20031 Record the start and end dates"^^xsd:string ;
1051 sp:templates ([ sp:object 1047 sp:templates ([ sp:object
1048 + [ sp:varName "dateStart"^^xsd:string
1049 + ] ;
1050 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
1051 + sp:subject
1052 + [ sp:varName "productionFlow"^^xsd:string
1053 + ]
1054 + ] [ sp:object
1052 [ sp:varName "dateEnd"^^xsd:string 1055 [ sp:varName "dateEnd"^^xsd:string
1053 ] ; 1056 ] ;
1054 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 1057 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
...@@ -1063,6 +1066,13 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ; ...@@ -1063,6 +1066,13 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ;
1063 [ sp:varName "productionFlowToDate"^^xsd:string 1066 [ sp:varName "productionFlowToDate"^^xsd:string
1064 ] 1067 ]
1065 ] [ sp:object 1068 ] [ sp:object
1069 + [ sp:varName "dateStart"^^xsd:string
1070 + ] ;
1071 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
1072 + sp:subject
1073 + [ sp:varName "productionInventory"^^xsd:string
1074 + ]
1075 + ] [ sp:object
1066 [ sp:varName "dateEnd"^^xsd:string 1076 [ sp:varName "dateEnd"^^xsd:string
1067 ] ; 1077 ] ;
1068 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 1078 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
...@@ -1077,6 +1087,13 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ; ...@@ -1077,6 +1087,13 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ;
1077 [ sp:varName "productionInventoryToDate"^^xsd:string 1087 [ sp:varName "productionInventoryToDate"^^xsd:string
1078 ] 1088 ]
1079 ] [ sp:object 1089 ] [ sp:object
1090 + [ sp:varName "dateStart"^^xsd:string
1091 + ] ;
1092 + sp:predicate <http://www.reportinghub.no/ep/schema/activity#startedAt> ;
1093 + sp:subject
1094 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1095 + ]
1096 + ] [ sp:object
1080 [ sp:varName "dateEnd"^^xsd:string 1097 [ sp:varName "dateEnd"^^xsd:string
1081 ] ; 1098 ] ;
1082 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ; 1099 sp:predicate <http://www.reportinghub.no/ep/schema/activity#finishedAt> ;
...@@ -1096,39 +1113,25 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ; ...@@ -1096,39 +1113,25 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ;
1096 ] ; 1113 ] ;
1097 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 1114 sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
1098 sp:subject spin:_this 1115 sp:subject spin:_this
1099 - ] [ sp:object
1100 - [ sp:varName "dateEnd"^^xsd:string
1101 - ] ;
1102 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalEnd> ;
1103 - sp:subject spin:_this
1104 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ; 1116 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
1105 sp:predicate rdf:type ; 1117 sp:predicate rdf:type ;
1106 sp:subject 1118 sp:subject
1107 [ sp:varName "productVolumeRef"^^xsd:string 1119 [ sp:varName "productVolumeRef"^^xsd:string
1108 ] 1120 ]
1109 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ; 1121 + ] [ sp:object
1110 - sp:predicate rdf:type ; 1122 + [ sp:varName "dateStart"^^xsd:string
1123 + ] ;
1124 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
1125 + sp:subject
1126 + [ sp:varName "productVolumeRef"^^xsd:string
1127 + ]
1128 + ] [ sp:object
1129 + [ sp:varName "dateEnd"^^xsd:string
1130 + ] ;
1131 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
1111 sp:subject 1132 sp:subject
1112 [ sp:varName "productVolumeRef"^^xsd:string 1133 [ sp:varName "productVolumeRef"^^xsd:string
1113 ] 1134 ]
1114 - ] [ rdf:type sp:NotExists ;
1115 - sp:elements ([ sp:object
1116 - [ sp:varName "dateEndx"^^xsd:string
1117 - ] ;
1118 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
1119 - sp:subject
1120 - [ sp:varName "productVolumeRef"^^xsd:string
1121 - ]
1122 - ])
1123 - ] [ rdf:type sp:NotExists ;
1124 - sp:elements ([ sp:object
1125 - [ sp:varName "dTimEndx"^^xsd:string
1126 - ] ;
1127 - sp:predicate <http://www.epim.no/schemas/mprml/1#dTimEnd> ;
1128 - sp:subject
1129 - [ sp:varName "productVolumeRef"^^xsd:string
1130 - ]
1131 - ])
1132 ] [ sp:object 1135 ] [ sp:object
1133 [ sp:varName "productVolumeRef"^^xsd:string 1136 [ sp:varName "productVolumeRef"^^xsd:string
1134 ] ; 1137 ] ;
...@@ -1202,6 +1205,97 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ; ...@@ -1202,6 +1205,97 @@ role is ignored, because it is implicitly \"operator\""""^^xsd:string ;
1202 [ sp:varName "productionFacilityToDate"^^xsd:string 1205 [ sp:varName "productionFacilityToDate"^^xsd:string
1203 ] 1206 ]
1204 ]) 1207 ])
1208 + ] ;
1209 + spin:rule
1210 + [ rdf:type sp:Construct ;
1211 + rdfs:comment "STEP 20012 Create the period ProductionInventory and the ProductionInventoryToDate - if necessary ."^^xsd:string ;
1212 + sp:templates ([ sp:object _:b7 ;
1213 + sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ;
1214 + sp:subject
1215 + [ sp:varName "productVolumeReport"^^xsd:string
1216 + ]
1217 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventory> ;
1218 + sp:predicate rdf:type ;
1219 + sp:subject _:b7
1220 + ] [ sp:object
1221 + [ sp:varName "productVolumeRef"^^xsd:string
1222 + ] ;
1223 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
1224 + sp:subject _:b7
1225 + ] [ sp:object _:b8 ;
1226 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
1227 + sp:subject _:b7
1228 + ] [ sp:object <http://www.reportinghub.no/ep/schema/flow#ProductionInventoryToDate> ;
1229 + sp:predicate rdf:type ;
1230 + sp:subject _:b8
1231 + ] [ sp:object _:b7 ;
1232 + sp:predicate <http://www.reportinghub.no/ep/schema/core#hasSpatialPart> ;
1233 + sp:subject
1234 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1235 + ]
1236 + ] [ sp:object _:b8 ;
1237 + sp:predicate <http://www.reportinghub.no/ep/schema/core#hasSpatialPart> ;
1238 + sp:subject
1239 + [ sp:varName "productionFacilityToDate"^^xsd:string
1240 + ]
1241 + ]) ;
1242 + sp:where ([ sp:object spin:_this ;
1243 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
1244 + sp:subject
1245 + [ sp:varName "productionReport"^^xsd:string
1246 + ]
1247 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
1248 + sp:predicate rdf:type ;
1249 + sp:subject
1250 + [ sp:varName "productionReport"^^xsd:string
1251 + ]
1252 + ] [ sp:object
1253 + [ sp:varName "productVolumeRef"^^xsd:string
1254 + ] ;
1255 + sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
1256 + sp:subject spin:_this
1257 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
1258 + sp:predicate rdf:type ;
1259 + sp:subject
1260 + [ sp:varName "productVolumeRef"^^xsd:string
1261 + ]
1262 + ] [ sp:object
1263 + [ sp:varName "productVolumeRef"^^xsd:string
1264 + ] ;
1265 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
1266 + sp:subject
1267 + [ sp:varName "productVolumeReport"^^xsd:string
1268 + ]
1269 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductVolumeReport> ;
1270 + sp:predicate rdf:type ;
1271 + sp:subject
1272 + [ sp:varName "productVolumeReport"^^xsd:string
1273 + ]
1274 + ] [ sp:object
1275 + [ sp:varName "productVolumeRef"^^xsd:string
1276 + ] ;
1277 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
1278 + sp:subject
1279 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1280 + ]
1281 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
1282 + sp:predicate rdf:type ;
1283 + sp:subject
1284 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1285 + ]
1286 + ] [ sp:object
1287 + [ sp:varName "productionFacilityToDate"^^xsd:string
1288 + ] ;
1289 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
1290 + sp:subject
1291 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
1292 + ]
1293 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacilityToDate> ;
1294 + sp:predicate rdf:type ;
1295 + sp:subject
1296 + [ sp:varName "productionFacilityToDate"^^xsd:string
1297 + ]
1298 + ])
1205 ] . 1299 ] .
1206 1300
1207 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-productVolumeReport-v1.0> 1301 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-productVolumeReport-v1.0>
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
20 <http://www.epim.no/schemas/mprml/1#A_Global-Objects> 20 <http://www.epim.no/schemas/mprml/1#A_Global-Objects>
21 spin:rule 21 spin:rule
22 [ rdf:type sp:Construct ; 22 [ rdf:type sp:Construct ;
23 - rdfs:comment "STEP 10001m Create the ProductionReport - extract the name from productVolume/installation where the installation is a field"^^xsd:string ; 23 + rdfs:comment "STEP 10001m Create the ProductionReport - extract the report name from context/contextFacility"^^xsd:string ;
24 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ; 24 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
25 sp:predicate rdf:type ; 25 sp:predicate rdf:type ;
26 sp:subject 26 sp:subject
...@@ -38,48 +38,36 @@ ...@@ -38,48 +38,36 @@
38 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 38 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
39 sp:subject spin:_this 39 sp:subject spin:_this
40 ] [ sp:object 40 ] [ sp:object
41 - [ sp:varName "productVolumeRef"^^xsd:string 41 + [ sp:varName "contextRef"^^xsd:string
42 ] ; 42 ] ;
43 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 43 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
44 sp:subject spin:_this 44 sp:subject spin:_this
45 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ; 45 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
46 sp:predicate rdf:type ; 46 sp:predicate rdf:type ;
47 sp:subject 47 sp:subject
48 - [ sp:varName "productVolumeRef"^^xsd:string 48 + [ sp:varName "contextRef"^^xsd:string
49 - ]
50 - ] [ sp:object
51 - [ sp:varName "installationRef"^^xsd:string
52 - ] ;
53 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
54 - sp:subject
55 - [ sp:varName "productVolumeRef"^^xsd:string
56 - ]
57 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
58 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
59 - sp:subject
60 - [ sp:varName "installationRef"^^xsd:string
61 ] 49 ]
62 ] [ sp:object 50 ] [ sp:object
63 - [ sp:varName "installationRef"^^xsd:string 51 + [ sp:varName "contextFacilityRef"^^xsd:string
64 ] ; 52 ] ;
65 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 53 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ;
66 sp:subject 54 sp:subject
67 - [ sp:varName "installation"^^xsd:string 55 + [ sp:varName "contextRef"^^xsd:string
68 ] 56 ]
69 ] [ rdf:type sp:Bind ; 57 ] [ rdf:type sp:Bind ;
70 sp:expression 58 sp:expression
71 [ rdf:type spl:object ; 59 [ rdf:type spl:object ;
72 - sp:arg1 [ sp:varName "installationRef"^^xsd:string 60 + sp:arg1 [ sp:varName "contextFacilityRef"^^xsd:string
73 ] ; 61 ] ;
74 sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> 62 sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText>
75 ] ; 63 ] ;
76 sp:variable 64 sp:variable
77 - [ sp:varName "normalizedInstallationName"^^xsd:string 65 + [ sp:varName "normalizedContextFacilityName"^^xsd:string
78 ] 66 ]
79 ] [ rdf:type sp:Bind ; 67 ] [ rdf:type sp:Bind ;
80 sp:expression 68 sp:expression
81 [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ; 69 [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ;
82 - sp:arg1 [ sp:varName "normalizedInstallationName"^^xsd:string 70 + sp:arg1 [ sp:varName "normalizedContextFacilityName"^^xsd:string
83 ] ; 71 ] ;
84 sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string 72 sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string
85 ] 73 ]
...@@ -91,14 +79,14 @@ ...@@ -91,14 +79,14 @@
91 ] ; 79 ] ;
92 spin:rule 80 spin:rule
93 [ rdf:type sp:Construct ; 81 [ rdf:type sp:Construct ;
94 - rdfs:comment "STEP 10001a Create the inteval identifier - dateStart and dateEnd from context"^^xsd:string ; 82 + rdfs:comment "STEP 10001b Create the interval identifier - date and dateEnd from context"^^xsd:string ;
95 sp:templates ([ sp:object 83 sp:templates ([ sp:object
96 [ sp:varName "intervalIdentifier"^^xsd:string 84 [ sp:varName "intervalIdentifier"^^xsd:string
97 ] ; 85 ] ;
98 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 86 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
99 sp:subject spin:_this 87 sp:subject spin:_this
100 ] [ sp:object 88 ] [ sp:object
101 - [ sp:varName "dateStart"^^xsd:string 89 + [ sp:varName "date"^^xsd:string
102 ] ; 90 ] ;
103 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ; 91 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ;
104 sp:subject spin:_this 92 sp:subject spin:_this
...@@ -119,12 +107,21 @@ ...@@ -119,12 +107,21 @@
119 [ sp:varName "contextRef"^^xsd:string 107 [ sp:varName "contextRef"^^xsd:string
120 ] 108 ]
121 ] [ sp:object 109 ] [ sp:object
122 - [ sp:varName "dateStart"^^xsd:string 110 + [ sp:varName "date"^^xsd:string
123 ] ; 111 ] ;
124 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ; 112 + sp:predicate <http://www.epim.no/schemas/mprml/1#date> ;
125 sp:subject 113 sp:subject
126 [ sp:varName "contextRef"^^xsd:string 114 [ sp:varName "contextRef"^^xsd:string
127 ] 115 ]
116 + ] [ rdf:type sp:NotExists ;
117 + sp:elements ([ sp:object
118 + [ sp:varName "dateStart"^^xsd:string
119 + ] ;
120 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
121 + sp:subject
122 + [ sp:varName "contextRef"^^xsd:string
123 + ]
124 + ])
128 ] [ sp:object 125 ] [ sp:object
129 [ sp:varName "dateEnd"^^xsd:string 126 [ sp:varName "dateEnd"^^xsd:string
130 ] ; 127 ] ;
...@@ -135,7 +132,7 @@ ...@@ -135,7 +132,7 @@
135 ] [ rdf:type sp:Bind ; 132 ] [ rdf:type sp:Bind ;
136 sp:expression 133 sp:expression
137 [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ; 134 [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ;
138 - sp:arg1 [ sp:varName "dateStart"^^xsd:string 135 + sp:arg1 [ sp:varName "date"^^xsd:string
139 ] ; 136 ] ;
140 sp:arg2 [ sp:varName "dateEnd"^^xsd:string 137 sp:arg2 [ sp:varName "dateEnd"^^xsd:string
141 ] 138 ]
...@@ -203,14 +200,22 @@ ...@@ -203,14 +200,22 @@
203 ] ; 200 ] ;
204 spin:rule 201 spin:rule
205 [ rdf:type sp:Construct ; 202 [ rdf:type sp:Construct ;
206 - rdfs:comment "STEP 10010 Add the contextFacility"^^xsd:string ; 203 + rdfs:comment "STEP 10001d Create the interval identifier - dateEnd from context"^^xsd:string ;
207 sp:templates ([ sp:object 204 sp:templates ([ sp:object
208 - [ sp:varName "contextFacility"^^xsd:string 205 + [ sp:varName "dateEnd"^^xsd:string
209 ] ; 206 ] ;
210 - sp:predicate <http://www.reportinghub.no/ep/schema/geography#locatedWithin> ; 207 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
211 - sp:subject 208 + sp:subject spin:_this
212 - [ sp:varName "productionFacility"^^xsd:string 209 + ] [ sp:object
213 - ] 210 + [ sp:varName "dateEnd"^^xsd:string
211 + ] ;
212 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ;
213 + sp:subject spin:_this
214 + ] [ sp:object
215 + [ sp:varName "dateEnd"^^xsd:string
216 + ] ;
217 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalEnd> ;
218 + sp:subject spin:_this
214 ]) ; 219 ]) ;
215 sp:where ([ sp:object 220 sp:where ([ sp:object
216 [ sp:varName "contextRef"^^xsd:string 221 [ sp:varName "contextRef"^^xsd:string
...@@ -223,58 +228,110 @@ ...@@ -223,58 +228,110 @@
223 [ sp:varName "contextRef"^^xsd:string 228 [ sp:varName "contextRef"^^xsd:string
224 ] 229 ]
225 ] [ sp:object 230 ] [ sp:object
226 - [ sp:varName "contectFacilityRef"^^xsd:string 231 + [ sp:varName "dateEnd"^^xsd:string
227 ] ; 232 ] ;
228 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ; 233 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
229 sp:subject 234 sp:subject
230 [ sp:varName "contextRef"^^xsd:string 235 [ sp:varName "contextRef"^^xsd:string
231 ] 236 ]
232 - ] [ sp:object 237 + ] [ rdf:type sp:NotExists ;
233 - [ sp:varName "contextFacilityRef"^^xsd:string 238 + sp:elements ([ sp:object
239 + [ sp:varName "date"^^xsd:string
240 + ] ;
241 + sp:predicate <http://www.epim.no/schemas/mprml/1#date> ;
242 + sp:subject
243 + [ sp:varName "contextRef"^^xsd:string
244 + ]
245 + ])
246 + ] [ rdf:type sp:NotExists ;
247 + sp:elements ([ sp:object
248 + [ sp:varName "dateStart"^^xsd:string
249 + ] ;
250 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
251 + sp:subject
252 + [ sp:varName "contextRef"^^xsd:string
253 + ]
254 + ])
255 + ])
256 + ] ;
257 + spin:rule
258 + [ rdf:type sp:Construct ;
259 + rdfs:comment "STEP 10001z Add the issue date and title"^^xsd:string ;
260 + sp:templates ([ sp:object
261 + [ sp:varName "month"^^xsd:string
234 ] ; 262 ] ;
235 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 263 + sp:predicate <http://www.reportinghub.no/ep/schema/report#issuedAt> ;
236 - sp:subject
237 - [ sp:varName "contextFacility"^^xsd:string
238 - ]
239 - ] [ sp:object spin:_this ;
240 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
241 sp:subject 264 sp:subject
242 [ sp:varName "productionReport"^^xsd:string 265 [ sp:varName "productionReport"^^xsd:string
243 ] 266 ]
244 ] [ sp:object 267 ] [ sp:object
245 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 268 + [ sp:varName "title"^^xsd:string
246 ] ; 269 ] ;
247 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportSubmittedBy> ; 270 + sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
248 sp:subject 271 sp:subject
249 [ sp:varName "productionReport"^^xsd:string 272 [ sp:varName "productionReport"^^xsd:string
250 ] 273 ]
251 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ; 274 + ]) ;
275 + sp:where ([ sp:object
276 + [ sp:varName "contextRef"^^xsd:string
277 + ] ;
278 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
279 + sp:subject spin:_this
280 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
252 sp:predicate rdf:type ; 281 sp:predicate rdf:type ;
253 sp:subject 282 sp:subject
254 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 283 + [ sp:varName "contextRef"^^xsd:string
255 ] 284 ]
256 - ] [ sp:object 285 + ] [ rdf:type sp:Optional ;
257 - [ sp:varName "productionFacility"^^xsd:string 286 + sp:elements ([ sp:object
258 - ] ; 287 + [ sp:varName "month"^^xsd:string
259 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 288 + ] ;
289 + sp:predicate <http://www.epim.no/schemas/mprml/1#month> ;
290 + sp:subject
291 + [ sp:varName "contextRef"^^xsd:string
292 + ]
293 + ])
294 + ] [ rdf:type sp:Optional ;
295 + sp:elements ([ sp:object
296 + [ sp:varName "titleRef"^^xsd:string
297 + ] ;
298 + sp:predicate <http://www.epim.no/schemas/mprml/1#titleRef> ;
299 + sp:subject
300 + [ sp:varName "contextRef"^^xsd:string
301 + ]
302 + ] [ sp:object
303 + [ sp:varName "title"^^xsd:string
304 + ] ;
305 + sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
306 + sp:subject
307 + [ sp:varName "titleRef"^^xsd:string
308 + ]
309 + ])
310 + ] [ sp:object spin:_this ;
311 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
260 sp:subject 312 sp:subject
261 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 313 + [ sp:varName "productionReport"^^xsd:string
314 + ]
315 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
316 + sp:predicate rdf:type ;
317 + sp:subject
318 + [ sp:varName "productionReport"^^xsd:string
262 ] 319 ]
263 ]) 320 ])
264 ] ; 321 ] ;
265 spin:rule 322 spin:rule
266 [ rdf:type sp:Construct ; 323 [ rdf:type sp:Construct ;
267 - rdfs:comment "STEP 10020 Add the operator"^^xsd:string ; 324 + rdfs:comment "STEP 10001r Set the submitting installation"^^xsd:string ;
268 sp:templates ([ sp:object _:b1 ; 325 sp:templates ([ sp:object _:b1 ;
269 - sp:predicate <http://www.reportinghub.no/ep/schema/facility#facilityOperator> ; 326 + sp:predicate <http://www.reportinghub.no/ep/schema/report#reportSubmittedBy> ;
270 sp:subject 327 sp:subject
271 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 328 + [ sp:varName "productionReport"^^xsd:string
272 ] 329 ]
273 - ] [ sp:object <http://www.reportinghub.no/ep/schema/organization#Organization> ; 330 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
274 sp:predicate rdf:type ; 331 sp:predicate rdf:type ;
275 sp:subject _:b1 332 sp:subject _:b1
276 ] [ sp:object 333 ] [ sp:object
277 - [ sp:varName "operator"^^xsd:string 334 + [ sp:varName "installation"^^xsd:string
278 ] ; 335 ] ;
279 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 336 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
280 sp:subject _:b1 337 sp:subject _:b1
...@@ -284,57 +341,104 @@ ...@@ -284,57 +341,104 @@
284 ] ; 341 ] ;
285 sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ; 342 sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
286 sp:subject spin:_this 343 sp:subject spin:_this
344 + ] [ sp:object spin:_this ;
345 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
346 + sp:subject
347 + [ sp:varName "productionReport"^^xsd:string
348 + ]
349 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
350 + sp:predicate rdf:type ;
351 + sp:subject
352 + [ sp:varName "productionReport"^^xsd:string
353 + ]
287 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ; 354 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
288 sp:predicate rdf:type ; 355 sp:predicate rdf:type ;
289 sp:subject 356 sp:subject
290 [ sp:varName "contextRef"^^xsd:string 357 [ sp:varName "contextRef"^^xsd:string
291 ] 358 ]
292 ] [ sp:object 359 ] [ sp:object
293 - [ sp:varName "operatorRef"^^xsd:string 360 + [ sp:varName "installationRef"^^xsd:string
294 ] ; 361 ] ;
295 - sp:predicate <http://www.epim.no/schemas/mprml/1#operatorRef> ; 362 + sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
296 sp:subject 363 sp:subject
297 [ sp:varName "contextRef"^^xsd:string 364 [ sp:varName "contextRef"^^xsd:string
298 ] 365 ]
299 ] [ sp:object 366 ] [ sp:object
300 - [ sp:varName "operatorRef"^^xsd:string 367 + [ sp:varName "installationRef"^^xsd:string
301 ] ; 368 ] ;
302 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 369 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
303 sp:subject 370 sp:subject
304 - [ sp:varName "operator"^^xsd:string 371 + [ sp:varName "installation"^^xsd:string
372 + ]
373 + ])
374 + ] ;
375 + spin:rule
376 + [ rdf:type sp:Construct ;
377 + rdfs:comment "STEP 10001n Create the ProductionReport - extract the report name from the reporting from the reporting installation"^^xsd:string ;
378 + sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
379 + sp:predicate rdf:type ;
380 + sp:subject
381 + [ sp:varName "productionReport"^^xsd:string
305 ] 382 ]
306 ] [ sp:object spin:_this ; 383 ] [ sp:object spin:_this ;
307 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 384 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
308 sp:subject 385 sp:subject
309 [ sp:varName "productionReport"^^xsd:string 386 [ sp:varName "productionReport"^^xsd:string
310 ] 387 ]
388 + ]) ;
389 + sp:where ([ sp:object
390 + [ sp:varName "intervalIdentifier"^^xsd:string
391 + ] ;
392 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
393 + sp:subject spin:_this
311 ] [ sp:object 394 ] [ sp:object
312 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 395 + [ sp:varName "contextRef"^^xsd:string
313 ] ; 396 ] ;
314 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportSubmittedBy> ; 397 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
398 + sp:subject spin:_this
399 + ] [ sp:object
400 + [ sp:varName "installationRef"^^xsd:string
401 + ] ;
402 + sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
315 sp:subject 403 sp:subject
316 - [ sp:varName "productionReport"^^xsd:string 404 + [ sp:varName "contextRef"^^xsd:string
317 ] 405 ]
318 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ; 406 + ] [ rdf:type sp:Bind ;
319 - sp:predicate rdf:type ; 407 + sp:expression
320 - sp:subject 408 + [ rdf:type spl:object ;
321 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 409 + sp:arg1 [ sp:varName "installationRef"^^xsd:string
410 + ] ;
411 + sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText>
412 + ] ;
413 + sp:variable
414 + [ sp:varName "normalizedInstallationName"^^xsd:string
415 + ]
416 + ] [ rdf:type sp:Bind ;
417 + sp:expression
418 + [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ;
419 + sp:arg1 [ sp:varName "normalizedInstallationName"^^xsd:string
420 + ] ;
421 + sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string
422 + ]
423 + ] ;
424 + sp:variable
425 + [ sp:varName "productionReport"^^xsd:string
322 ] 426 ]
323 ]) 427 ])
324 ] ; 428 ] ;
325 spin:rule 429 spin:rule
326 [ rdf:type sp:Construct ; 430 [ rdf:type sp:Construct ;
327 - rdfs:comment "STEP 10001q Set the submitting installation"^^xsd:string ; 431 + rdfs:comment "STEP 10020 Add the operator"^^xsd:string ;
328 sp:templates ([ sp:object _:b2 ; 432 sp:templates ([ sp:object _:b2 ;
329 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportSubmittedBy> ; 433 + sp:predicate <http://www.reportinghub.no/ep/schema/facility#facilityOperator> ;
330 sp:subject 434 sp:subject
331 - [ sp:varName "productionReport"^^xsd:string 435 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
332 ] 436 ]
333 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ; 437 + ] [ sp:object <http://www.reportinghub.no/ep/schema/organization#Organization> ;
334 sp:predicate rdf:type ; 438 sp:predicate rdf:type ;
335 sp:subject _:b2 439 sp:subject _:b2
336 ] [ sp:object 440 ] [ sp:object
337 - [ sp:varName "installation"^^xsd:string 441 + [ sp:varName "operator"^^xsd:string
338 ] ; 442 ] ;
339 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 443 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
340 sp:subject _:b2 444 sp:subject _:b2
...@@ -344,49 +448,54 @@ ...@@ -344,49 +448,54 @@
344 ] ; 448 ] ;
345 sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ; 449 sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
346 sp:subject spin:_this 450 sp:subject spin:_this
347 - ] [ sp:object spin:_this ;
348 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
349 - sp:subject
350 - [ sp:varName "productionReport"^^xsd:string
351 - ]
352 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ; 451 ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
353 sp:predicate rdf:type ; 452 sp:predicate rdf:type ;
354 sp:subject 453 sp:subject
355 [ sp:varName "contextRef"^^xsd:string 454 [ sp:varName "contextRef"^^xsd:string
356 ] 455 ]
357 ] [ sp:object 456 ] [ sp:object
358 - [ sp:varName "installationRef"^^xsd:string 457 + [ sp:varName "operatorRef"^^xsd:string
359 ] ; 458 ] ;
360 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ; 459 + sp:predicate <http://www.epim.no/schemas/mprml/1#operatorRef> ;
361 sp:subject 460 sp:subject
362 [ sp:varName "contextRef"^^xsd:string 461 [ sp:varName "contextRef"^^xsd:string
363 ] 462 ]
364 ] [ sp:object 463 ] [ sp:object
365 - [ sp:varName "installationRef"^^xsd:string 464 + [ sp:varName "operatorRef"^^xsd:string
366 ] ; 465 ] ;
367 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 466 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
368 sp:subject 467 sp:subject
369 - [ sp:varName "installation"^^xsd:string 468 + [ sp:varName "operator"^^xsd:string
469 + ]
470 + ] [ sp:object spin:_this ;
471 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
472 + sp:subject
473 + [ sp:varName "productionReport"^^xsd:string
474 + ]
475 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
476 + sp:predicate rdf:type ;
477 + sp:subject
478 + [ sp:varName "productionReport"^^xsd:string
370 ] 479 ]
371 - ])
372 - ] ;
373 - spin:rule
374 - [ rdf:type sp:Construct ;
375 - rdfs:comment "STEP 10001d Create the interval identifier - dateEnd from context"^^xsd:string ;
376 - sp:templates ([ sp:object
377 - [ sp:varName "dateEnd"^^xsd:string
378 - ] ;
379 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
380 - sp:subject spin:_this
381 - ] [ sp:object
382 - [ sp:varName "dateEnd"^^xsd:string
383 - ] ;
384 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ;
385 - sp:subject spin:_this
386 ] [ sp:object 480 ] [ sp:object
387 - [ sp:varName "dateEnd"^^xsd:string 481 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
388 ] ; 482 ] ;
389 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalEnd> ; 483 + sp:predicate <http://www.reportinghub.no/ep/schema/report#reportSubmittedBy> ;
484 + sp:subject
485 + [ sp:varName "productionReport"^^xsd:string
486 + ]
487 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
488 + sp:predicate rdf:type ;
489 + sp:subject
490 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
491 + ]
492 + ])
493 + ] ;
494 + spin:rule
495 + [ rdf:type sp:Construct ;
496 + rdfs:comment "STEP 10001e Create the interval identifier - no date"^^xsd:string ;
497 + sp:templates ([ sp:object "noDate" ;
498 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
390 sp:subject spin:_this 499 sp:subject spin:_this
391 ]) ; 500 ]) ;
392 sp:where ([ sp:object 501 sp:where ([ sp:object
...@@ -399,13 +508,15 @@ ...@@ -399,13 +508,15 @@
399 sp:subject 508 sp:subject
400 [ sp:varName "contextRef"^^xsd:string 509 [ sp:varName "contextRef"^^xsd:string
401 ] 510 ]
402 - ] [ sp:object 511 + ] [ rdf:type sp:NotExists ;
403 - [ sp:varName "dateEnd"^^xsd:string 512 + sp:elements ([ sp:object
404 - ] ; 513 + [ sp:varName "dateEnd"^^xsd:string
405 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ; 514 + ] ;
406 - sp:subject 515 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
407 - [ sp:varName "contextRef"^^xsd:string 516 + sp:subject
408 - ] 517 + [ sp:varName "contextRef"^^xsd:string
518 + ]
519 + ])
409 ] [ rdf:type sp:NotExists ; 520 ] [ rdf:type sp:NotExists ;
410 sp:elements ([ sp:object 521 sp:elements ([ sp:object
411 [ sp:varName "date"^^xsd:string 522 [ sp:varName "date"^^xsd:string
...@@ -428,21 +539,21 @@ ...@@ -428,21 +539,21 @@
428 ] ; 539 ] ;
429 spin:rule 540 spin:rule
430 [ rdf:type sp:Construct ; 541 [ rdf:type sp:Construct ;
431 - rdfs:comment "STEP 10001b Create the interval identifier - date and dateEnd from context"^^xsd:string ; 542 + rdfs:comment "STEP 10001o Set the default production facility from context/contextFacility"^^xsd:string ;
432 - sp:templates ([ sp:object 543 + sp:templates ([ sp:object spin:_this ;
433 - [ sp:varName "intervalIdentifier"^^xsd:string 544 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
434 - ] ; 545 + sp:subject
435 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 546 + [ sp:varName "productionFacility"^^xsd:string
436 - sp:subject spin:_this 547 + ]
437 - ] [ sp:object 548 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#ProductionFacility> ;
438 - [ sp:varName "date"^^xsd:string 549 + sp:predicate rdf:type ;
439 - ] ; 550 + sp:subject
440 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ; 551 + [ sp:varName "productionFacility"^^xsd:string
441 - sp:subject spin:_this 552 + ]
442 ] [ sp:object 553 ] [ sp:object
443 - [ sp:varName "dateEnd"^^xsd:string 554 + [ sp:varName "normalizedProductionFacilityName"^^xsd:string
444 ] ; 555 ] ;
445 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalEnd> ; 556 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText> ;
446 sp:subject spin:_this 557 sp:subject spin:_this
447 ]) ; 558 ]) ;
448 sp:where ([ sp:object 559 sp:where ([ sp:object
...@@ -456,57 +567,40 @@ ...@@ -456,57 +567,40 @@
456 [ sp:varName "contextRef"^^xsd:string 567 [ sp:varName "contextRef"^^xsd:string
457 ] 568 ]
458 ] [ sp:object 569 ] [ sp:object
459 - [ sp:varName "date"^^xsd:string 570 + [ sp:varName "contextFacilityRef"^^xsd:string
460 ] ; 571 ] ;
461 - sp:predicate <http://www.epim.no/schemas/mprml/1#date> ; 572 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ;
462 sp:subject 573 sp:subject
463 [ sp:varName "contextRef"^^xsd:string 574 [ sp:varName "contextRef"^^xsd:string
464 ] 575 ]
465 - ] [ rdf:type sp:NotExists ;
466 - sp:elements ([ sp:object
467 - [ sp:varName "dateStart"^^xsd:string
468 - ] ;
469 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
470 - sp:subject
471 - [ sp:varName "contextRef"^^xsd:string
472 - ]
473 - ])
474 ] [ sp:object 576 ] [ sp:object
475 - [ sp:varName "dateEnd"^^xsd:string 577 + [ sp:varName "contextFacilityRef"^^xsd:string
476 ] ; 578 ] ;
477 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ; 579 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
478 sp:subject 580 sp:subject
479 - [ sp:varName "contextRef"^^xsd:string 581 + [ sp:varName "productionFacility"^^xsd:string
480 ] 582 ]
481 ] [ rdf:type sp:Bind ; 583 ] [ rdf:type sp:Bind ;
482 sp:expression 584 sp:expression
483 - [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ; 585 + [ rdf:type spl:object ;
484 - sp:arg1 [ sp:varName "date"^^xsd:string 586 + sp:arg1 [ sp:varName "contextFacilityRef"^^xsd:string
485 ] ; 587 ] ;
486 - sp:arg2 [ sp:varName "dateEnd"^^xsd:string 588 + sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText>
487 - ]
488 ] ; 589 ] ;
489 sp:variable 590 sp:variable
490 - [ sp:varName "intervalIdentifier"^^xsd:string 591 + [ sp:varName "normalizedProductionFacilityName"^^xsd:string
491 ] 592 ]
492 ]) 593 ])
493 ] ; 594 ] ;
494 spin:rule 595 spin:rule
495 [ rdf:type sp:Construct ; 596 [ rdf:type sp:Construct ;
496 - rdfs:comment "STEP 10001z Add the issue date and title"^^xsd:string ; 597 + rdfs:comment "STEP 10010 Add the contextFacility - unless the contextFacility is the production facility"^^xsd:string ;
497 sp:templates ([ sp:object 598 sp:templates ([ sp:object
498 - [ sp:varName "month"^^xsd:string 599 + [ sp:varName "contextFacility"^^xsd:string
499 - ] ;
500 - sp:predicate <http://www.reportinghub.no/ep/schema/report#issuedAt> ;
501 - sp:subject
502 - [ sp:varName "productionReport"^^xsd:string
503 - ]
504 - ] [ sp:object
505 - [ sp:varName "title"^^xsd:string
506 ] ; 600 ] ;
507 - sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ; 601 + sp:predicate <http://www.reportinghub.no/ep/schema/geography#locatedWithin> ;
508 sp:subject 602 sp:subject
509 - [ sp:varName "productionReport"^^xsd:string 603 + [ sp:varName "productionFacility"^^xsd:string
510 ] 604 ]
511 ]) ; 605 ]) ;
512 sp:where ([ sp:object 606 sp:where ([ sp:object
...@@ -519,29 +613,25 @@ ...@@ -519,29 +613,25 @@
519 sp:subject 613 sp:subject
520 [ sp:varName "contextRef"^^xsd:string 614 [ sp:varName "contextRef"^^xsd:string
521 ] 615 ]
522 - ] [ rdf:type sp:Optional ; 616 + ] [ sp:object
523 - sp:elements ([ sp:object 617 + [ sp:varName "contextFacilityRef"^^xsd:string
524 - [ sp:varName "month"^^xsd:string 618 + ] ;
525 - ] ; 619 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ;
526 - sp:predicate <http://www.epim.no/schemas/mprml/1#month> ; 620 + sp:subject
527 - sp:subject 621 + [ sp:varName "contextRef"^^xsd:string
528 - [ sp:varName "contextRef"^^xsd:string 622 + ]
529 - ] 623 + ] [ sp:object
530 - ]) 624 + [ sp:varName "contextFacilityRef"^^xsd:string
531 - ] [ rdf:type sp:Optional ; 625 + ] ;
532 - sp:elements ([ sp:object 626 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
533 - [ sp:varName "titleRef"^^xsd:string 627 + sp:subject
534 - ] ; 628 + [ sp:varName "contextFacility"^^xsd:string
535 - sp:predicate <http://www.epim.no/schemas/mprml/1#titleRef> ; 629 + ]
536 - sp:subject 630 + ] [ rdf:type sp:NotExists ;
537 - [ sp:varName "contextRef"^^xsd:string 631 + sp:elements ([ sp:object spin:_this ;
538 - ] 632 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
539 - ] [ sp:object
540 - [ sp:varName "title"^^xsd:string
541 - ] ;
542 - sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
543 sp:subject 633 sp:subject
544 - [ sp:varName "titleRef"^^xsd:string 634 + [ sp:varName "contextFacility"^^xsd:string
545 ] 635 ]
546 ]) 636 ])
547 ] [ sp:object spin:_this ; 637 ] [ sp:object spin:_this ;
...@@ -549,217 +639,91 @@ ...@@ -549,217 +639,91 @@
549 sp:subject 639 sp:subject
550 [ sp:varName "productionReport"^^xsd:string 640 [ sp:varName "productionReport"^^xsd:string
551 ] 641 ]
552 - ]) 642 + ] [ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
553 - ] ;
554 - spin:rule
555 - [ rdf:type sp:Construct ;
556 - rdfs:comment "STEP 10001o Create the ProductionReport - unable to find a name"^^xsd:string ;
557 - sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
558 sp:predicate rdf:type ; 643 sp:predicate rdf:type ;
559 sp:subject 644 sp:subject
560 [ sp:varName "productionReport"^^xsd:string 645 [ sp:varName "productionReport"^^xsd:string
561 ] 646 ]
562 - ] [ sp:object spin:_this ; 647 + ] [ sp:object
563 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 648 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
649 + ] ;
650 + sp:predicate <http://www.reportinghub.no/ep/schema/report#reportSubmittedBy> ;
564 sp:subject 651 sp:subject
565 [ sp:varName "productionReport"^^xsd:string 652 [ sp:varName "productionReport"^^xsd:string
566 ] 653 ]
567 - ]) ; 654 + ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
568 - sp:where ([ sp:object 655 + sp:predicate rdf:type ;
569 - [ sp:varName "intervalIdentifier"^^xsd:string 656 + sp:subject
570 - ] ; 657 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
571 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
572 - sp:subject spin:_this
573 - ] [ rdf:type sp:NotExists ;
574 - sp:elements ([ sp:object
575 - [ sp:varName "productVolumeRef"^^xsd:string
576 - ] ;
577 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
578 - sp:subject spin:_this
579 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
580 - sp:predicate rdf:type ;
581 - sp:subject
582 - [ sp:varName "productVolumeRef"^^xsd:string
583 - ]
584 - ] [ sp:object
585 - [ sp:varName "installationRef"^^xsd:string
586 - ] ;
587 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
588 - sp:subject
589 - [ sp:varName "productVolumeRef"^^xsd:string
590 - ]
591 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
592 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
593 - sp:subject
594 - [ sp:varName "installationRef"^^xsd:string
595 - ]
596 - ])
597 - ] [ rdf:type sp:NotExists ;
598 - sp:elements ([ sp:object
599 - [ sp:varName "productionOperationRef"^^xsd:string
600 - ] ;
601 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
602 - sp:subject spin:_this
603 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productionOperation> ;
604 - sp:predicate rdf:type ;
605 - sp:subject
606 - [ sp:varName "productionOperationRef"^^xsd:string
607 - ]
608 - ] [ sp:object
609 - [ sp:varName "installationRefx"^^xsd:string
610 - ] ;
611 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
612 - sp:subject
613 - [ sp:varName "productionOperationRef"^^xsd:string
614 - ]
615 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
616 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
617 - sp:subject
618 - [ sp:varName "installationRefx"^^xsd:string
619 - ]
620 - ])
621 - ] [ rdf:type sp:Bind ;
622 - sp:expression
623 - [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ;
624 - sp:arg1 "installation-not-specified" ;
625 - sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string
626 - ]
627 - ] ;
628 - sp:variable
629 - [ sp:varName "productionReport"^^xsd:string
630 ] 658 ]
631 - ]) 659 + ] [ sp:object
632 - ] ; 660 + [ sp:varName "productionFacility"^^xsd:string
633 - spin:rule
634 - [ rdf:type sp:Construct ;
635 - rdfs:comment "STEP 10001e Create the interval identifier - no date"^^xsd:string ;
636 - sp:templates ([ sp:object "noDate" ;
637 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
638 - sp:subject spin:_this
639 - ]) ;
640 - sp:where ([ sp:object
641 - [ sp:varName "contextRef"^^xsd:string
642 ] ; 661 ] ;
643 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ; 662 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
644 - sp:subject spin:_this
645 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
646 - sp:predicate rdf:type ;
647 sp:subject 663 sp:subject
648 - [ sp:varName "contextRef"^^xsd:string 664 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
649 ] 665 ]
650 - ] [ rdf:type sp:NotExists ;
651 - sp:elements ([ sp:object
652 - [ sp:varName "dateEnd"^^xsd:string
653 - ] ;
654 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
655 - sp:subject
656 - [ sp:varName "contextRef"^^xsd:string
657 - ]
658 - ])
659 - ] [ rdf:type sp:NotExists ;
660 - sp:elements ([ sp:object
661 - [ sp:varName "date"^^xsd:string
662 - ] ;
663 - sp:predicate <http://www.epim.no/schemas/mprml/1#date> ;
664 - sp:subject
665 - [ sp:varName "contextRef"^^xsd:string
666 - ]
667 - ])
668 - ] [ rdf:type sp:NotExists ;
669 - sp:elements ([ sp:object
670 - [ sp:varName "dateStart"^^xsd:string
671 - ] ;
672 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
673 - sp:subject
674 - [ sp:varName "contextRef"^^xsd:string
675 - ]
676 - ])
677 ]) 666 ])
678 ] ; 667 ] ;
679 spin:rule 668 spin:rule
680 [ rdf:type sp:Construct ; 669 [ rdf:type sp:Construct ;
681 - rdfs:comment "STEP 10001p Create the ProductionReport - check that different installations are not specified"^^xsd:string ; 670 + rdfs:comment "STEP 10001a Create the inteval identifier - dateStart and dateEnd from context"^^xsd:string ;
682 - sp:templates ([ sp:object "Error - different installations specified for different parts of the same report" ; 671 + sp:templates ([ sp:object
683 - sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
684 - sp:subject
685 - [ sp:varName "productionReport"^^xsd:string
686 - ]
687 - ]) ;
688 - sp:where ([ sp:object
689 [ sp:varName "intervalIdentifier"^^xsd:string 672 [ sp:varName "intervalIdentifier"^^xsd:string
690 ] ; 673 ] ;
691 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 674 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
692 sp:subject spin:_this 675 sp:subject spin:_this
693 ] [ sp:object 676 ] [ sp:object
694 - [ sp:varName "productVolumeRef"^^xsd:string 677 + [ sp:varName "dateStart"^^xsd:string
695 ] ; 678 ] ;
696 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 679 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalStart> ;
697 sp:subject spin:_this 680 sp:subject spin:_this
698 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
699 - sp:predicate rdf:type ;
700 - sp:subject
701 - [ sp:varName "productVolumeRef"^^xsd:string
702 - ]
703 ] [ sp:object 681 ] [ sp:object
704 - [ sp:varName "installationRef"^^xsd:string 682 + [ sp:varName "dateEnd"^^xsd:string
705 ] ; 683 ] ;
706 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ; 684 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalEnd> ;
707 - sp:subject 685 + sp:subject spin:_this
708 - [ sp:varName "productVolumeRef"^^xsd:string 686 + ]) ;
709 - ] 687 + sp:where ([ sp:object
710 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ; 688 + [ sp:varName "contextRef"^^xsd:string
711 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
712 - sp:subject
713 - [ sp:varName "installationRef"^^xsd:string
714 - ]
715 - ] [ sp:object
716 - [ sp:varName "productionOperationRef"^^xsd:string
717 ] ; 689 ] ;
718 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 690 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
719 sp:subject spin:_this 691 sp:subject spin:_this
720 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productionOperation> ; 692 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
721 sp:predicate rdf:type ; 693 sp:predicate rdf:type ;
722 sp:subject 694 sp:subject
723 - [ sp:varName "productionOperationRef"^^xsd:string 695 + [ sp:varName "contextRef"^^xsd:string
724 ] 696 ]
725 ] [ sp:object 697 ] [ sp:object
726 - [ sp:varName "installationRefx"^^xsd:string 698 + [ sp:varName "dateStart"^^xsd:string
727 ] ; 699 ] ;
728 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ; 700 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
729 sp:subject 701 sp:subject
730 - [ sp:varName "productionOperationRef"^^xsd:string 702 + [ sp:varName "contextRef"^^xsd:string
731 ] 703 ]
732 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ; 704 + ] [ sp:object
733 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 705 + [ sp:varName "dateEnd"^^xsd:string
706 + ] ;
707 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
734 sp:subject 708 sp:subject
735 - [ sp:varName "installationRefx"^^xsd:string 709 + [ sp:varName "contextRef"^^xsd:string
736 ] 710 ]
737 - ] [ rdf:type sp:NotExists ; 711 + ] [ rdf:type sp:Bind ;
738 - sp:elements ([ sp:object 712 + sp:expression
739 - [ sp:varName "installationRef"^^xsd:string 713 + [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ;
740 - ] ; 714 + sp:arg1 [ sp:varName "dateStart"^^xsd:string
741 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 715 + ] ;
742 - sp:subject 716 + sp:arg2 [ sp:varName "dateEnd"^^xsd:string
743 - [ sp:varName "installation"^^xsd:string 717 + ]
744 - ] 718 + ] ;
745 - ] [ sp:object 719 + sp:variable
746 - [ sp:varName "installationRefx"^^xsd:string 720 + [ sp:varName "intervalIdentifier"^^xsd:string
747 - ] ;
748 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
749 - sp:subject
750 - [ sp:varName "installation"^^xsd:string
751 - ]
752 - ])
753 - ] [ sp:object spin:_this ;
754 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
755 - sp:subject
756 - [ sp:varName "productionReport"^^xsd:string
757 ] 721 ]
758 ]) 722 ])
759 ] ; 723 ] ;
760 spin:rule 724 spin:rule
761 [ rdf:type sp:Construct ; 725 [ rdf:type sp:Construct ;
762 - rdfs:comment "STEP 10001n Create the ProductionReport - extract the name from productionOperation/installation where the installation is a field"^^xsd:string ; 726 + rdfs:comment "STEP 10001p Create the ProductionReport - unable to find an identifier"^^xsd:string ;
763 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ; 727 sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
764 sp:predicate rdf:type ; 728 sp:predicate rdf:type ;
765 sp:subject 729 sp:subject
...@@ -776,74 +740,50 @@ ...@@ -776,74 +740,50 @@
776 ] ; 740 ] ;
777 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 741 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
778 sp:subject spin:_this 742 sp:subject spin:_this
779 - ] [ sp:object
780 - [ sp:varName "productionOperationRef"^^xsd:string
781 - ] ;
782 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
783 - sp:subject spin:_this
784 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productionOperation> ;
785 - sp:predicate rdf:type ;
786 - sp:subject
787 - [ sp:varName "productionOperationRef"^^xsd:string
788 - ]
789 - ] [ sp:object
790 - [ sp:varName "installationRef"^^xsd:string
791 - ] ;
792 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
793 - sp:subject
794 - [ sp:varName "productionOperationRef"^^xsd:string
795 - ]
796 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
797 - sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
798 - sp:subject
799 - [ sp:varName "installationRef"^^xsd:string
800 - ]
801 ] [ rdf:type sp:NotExists ; 743 ] [ rdf:type sp:NotExists ;
802 sp:elements ([ sp:object 744 sp:elements ([ sp:object
803 - [ sp:varName "productVolumeRef"^^xsd:string 745 + [ sp:varName "contextRef"^^xsd:string
804 ] ; 746 ] ;
805 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ; 747 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
806 sp:subject spin:_this 748 sp:subject spin:_this
807 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ; 749 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
808 sp:predicate rdf:type ; 750 sp:predicate rdf:type ;
809 sp:subject 751 sp:subject
810 - [ sp:varName "productVolumeRef"^^xsd:string 752 + [ sp:varName "contextRef"^^xsd:string
811 ] 753 ]
812 ] [ sp:object 754 ] [ sp:object
813 - [ sp:varName "installationRefx"^^xsd:string 755 + [ sp:varName "contextFacilityRef"^^xsd:string
814 ] ; 756 ] ;
815 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ; 757 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ;
816 sp:subject 758 sp:subject
817 - [ sp:varName "productVolumeRef"^^xsd:string 759 + [ sp:varName "contextRef"^^xsd:string
818 ] 760 ]
819 ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ; 761 ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
820 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ; 762 sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
821 sp:subject 763 sp:subject
822 - [ sp:varName "installationRefx"^^xsd:string 764 + [ sp:varName "contextFacilityRef"^^xsd:string
765 + ]
766 + ])
767 + ] [ rdf:type sp:NotExists ;
768 + sp:elements ([ sp:object
769 + [ sp:varName "installationRef"^^xsd:string
770 + ] ;
771 + sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
772 + sp:subject
773 + [ sp:varName "contextRef"^^xsd:string
774 + ]
775 + ] [ sp:object
776 + [ sp:varName "installationRef"^^xsd:string
777 + ] ;
778 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
779 + sp:subject
780 + [ sp:varName "reportingFacility"^^xsd:string
823 ] 781 ]
824 ]) 782 ])
825 - ] [ sp:object
826 - [ sp:varName "installationRef"^^xsd:string
827 - ] ;
828 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
829 - sp:subject
830 - [ sp:varName "installation"^^xsd:string
831 - ]
832 - ] [ rdf:type sp:Bind ;
833 - sp:expression
834 - [ rdf:type spl:object ;
835 - sp:arg1 [ sp:varName "installationRef"^^xsd:string
836 - ] ;
837 - sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText>
838 - ] ;
839 - sp:variable
840 - [ sp:varName "normalizedInstallationName"^^xsd:string
841 - ]
842 ] [ rdf:type sp:Bind ; 783 ] [ rdf:type sp:Bind ;
843 sp:expression 784 sp:expression
844 [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ; 785 [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ;
845 - sp:arg1 [ sp:varName "normalizedInstallationName"^^xsd:string 786 + sp:arg1 "" ;
846 - ] ;
847 sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string 787 sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string
848 ] 788 ]
849 ] ; 789 ] ;
...@@ -855,5 +795,5 @@ ...@@ -855,5 +795,5 @@
855 795
856 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-productionReport-v1.0> 796 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-productionReport-v1.0>
857 rdf:type owl:Ontology ; 797 rdf:type owl:Ontology ;
858 - owl:imports <http://www.reportinghub.no/ep/transform/transform-helper-schema> , <http://www.reportinghub.no/ep/dpr/spin/1.1/lib> , <http://spinrdf.org/spin> , <http://www.epim.no/schemas/mprml/1> , <http://www.reportinghub.no/ep/mpr/spin/1.1/lib> ; 798 + owl:imports <http://www.reportinghub.no/ep/mpr/spin/1.1/lib> , <http://www.epim.no/schemas/mprml/1> , <http://spinrdf.org/spin> , <http://www.reportinghub.no/ep/dpr/spin/1.1/lib> , <http://www.reportinghub.no/ep/transform/transform-helper-schema> ;
859 owl:versionInfo "Created with TopBraid Composer"^^xsd:string . 799 owl:versionInfo "Created with TopBraid Composer"^^xsd:string .
......