David Leal

Fixed URI for ProductiionReport

...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
13 13
14 <http://www.reportinghub.no/ep/schema/1.0/report> 14 <http://www.reportinghub.no/ep/schema/1.0/report>
15 rdf:type owl:Ontology ; 15 rdf:type owl:Ontology ;
16 - owl:imports <http://www.reportinghub.no/np/schema/1.0/npd> , <http://www.reportinghub.no/ep/schema/1.0/activity> , <http://www.reportinghub.no/ep/schema/1.0/core> , <http://www.reportinghub.no/ep/schema/1.0/equipment> , <http://www.reportinghub.no/ep/schema/1.0/well> ; 16 + owl:imports <http://www.reportinghub.no/ep/schema/1.0/well> , <http://www.reportinghub.no/ep/schema/1.0/equipment> , <http://www.reportinghub.no/ep/schema/1.0/core> , <http://www.reportinghub.no/ep/schema/1.0/activity> , <http://www.reportinghub.no/np/schema/1.0/npd> ;
17 owl:versionInfo "0.1.0"^^xsd:string . 17 owl:versionInfo "0.1.0"^^xsd:string .
18 18
19 ep-report:DailyDrillingReport 19 ep-report:DailyDrillingReport
...@@ -31,12 +31,12 @@ ep-report:DailyProductionReport ...@@ -31,12 +31,12 @@ ep-report:DailyProductionReport
31 rdfs:subClassOf ep-report:ProductionReport . 31 rdfs:subClassOf ep-report:ProductionReport .
32 32
33 ep-report:DailyReport 33 ep-report:DailyReport
34 - rdf:type owl:Class , ep-report:ReportPeriodType ; 34 + rdf:type ep-report:ReportPeriodType , owl:Class ;
35 rdfs:label "daily report"^^xsd:string ; 35 rdfs:label "daily report"^^xsd:string ;
36 rdfs:subClassOf ep-report:Report . 36 rdfs:subClassOf ep-report:Report .
37 37
38 ep-report:FinalDailyDrillingReport 38 ep-report:FinalDailyDrillingReport
39 - rdf:type ep-report:DailyDrillingReportFinalisationType , owl:Class ; 39 + rdf:type owl:Class , ep-report:DailyDrillingReportFinalisationType ;
40 rdfs:label "final daily drilling report"^^xsd:string ; 40 rdfs:label "final daily drilling report"^^xsd:string ;
41 rdfs:subClassOf ep-report:DailyDrillingReport . 41 rdfs:subClassOf ep-report:DailyDrillingReport .
42 42
...@@ -51,7 +51,7 @@ ep-report:MonthlyProductionReport ...@@ -51,7 +51,7 @@ ep-report:MonthlyProductionReport
51 rdfs:subClassOf ep-report:ProductionReport . 51 rdfs:subClassOf ep-report:ProductionReport .
52 52
53 ep-report:MonthlyReport 53 ep-report:MonthlyReport
54 - rdf:type owl:Class , ep-report:ReportPeriodType ; 54 + rdf:type ep-report:ReportPeriodType , owl:Class ;
55 rdfs:label "monthly report"^^xsd:string ; 55 rdfs:label "monthly report"^^xsd:string ;
56 rdfs:subClassOf ep-report:Report . 56 rdfs:subClassOf ep-report:Report .
57 57
...@@ -60,13 +60,8 @@ ep-report:NonProductivetimeReport ...@@ -60,13 +60,8 @@ ep-report:NonProductivetimeReport
60 rdfs:subClassOf ep-report:Report ; 60 rdfs:subClassOf ep-report:Report ;
61 rdfs:subClassOf 61 rdfs:subClassOf
62 [ rdf:type owl:Restriction ; 62 [ rdf:type owl:Restriction ;
63 - owl:allValuesFrom xsd:dateTime ;
64 - owl:onProperty ep-report:createdAt
65 - ] ;
66 - rdfs:subClassOf
67 - [ rdf:type owl:Restriction ;
68 owl:cardinality "1"^^xsd:nonNegativeInteger ; 63 owl:cardinality "1"^^xsd:nonNegativeInteger ;
69 - owl:onProperty ep-report:createdAt 64 + owl:onProperty ep-report:reportOn
70 ] ; 65 ] ;
71 rdfs:subClassOf 66 rdfs:subClassOf
72 [ rdf:type owl:Restriction ; 67 [ rdf:type owl:Restriction ;
...@@ -76,16 +71,21 @@ ep-report:NonProductivetimeReport ...@@ -76,16 +71,21 @@ ep-report:NonProductivetimeReport
76 rdfs:subClassOf 71 rdfs:subClassOf
77 [ rdf:type owl:Restriction ; 72 [ rdf:type owl:Restriction ;
78 owl:cardinality "1"^^xsd:nonNegativeInteger ; 73 owl:cardinality "1"^^xsd:nonNegativeInteger ;
79 - owl:onProperty ep-report:reportOn 74 + owl:onProperty ep-report:createdAt
75 + ] ;
76 + rdfs:subClassOf
77 + [ rdf:type owl:Restriction ;
78 + owl:allValuesFrom xsd:dateTime ;
79 + owl:onProperty ep-report:createdAt
80 ] . 80 ] .
81 81
82 ep-report:NormalDailyDrillingReport 82 ep-report:NormalDailyDrillingReport
83 - rdf:type ep-report:DailyDrillingReportFinalisationType , owl:Class ; 83 + rdf:type owl:Class , ep-report:DailyDrillingReportFinalisationType ;
84 rdfs:label "normal daily drilling report"^^xsd:string ; 84 rdfs:label "normal daily drilling report"^^xsd:string ;
85 rdfs:subClassOf ep-report:DailyDrillingReport . 85 rdfs:subClassOf ep-report:DailyDrillingReport .
86 86
87 ep-report:PreliminaryDailyDrillingReport 87 ep-report:PreliminaryDailyDrillingReport
88 - rdf:type ep-report:DailyDrillingReportFinalisationType , owl:Class ; 88 + rdf:type owl:Class , ep-report:DailyDrillingReportFinalisationType ;
89 rdfs:label "preliminary daily drilling report"^^xsd:string ; 89 rdfs:label "preliminary daily drilling report"^^xsd:string ;
90 rdfs:subClassOf ep-report:DailyDrillingReport . 90 rdfs:subClassOf ep-report:DailyDrillingReport .
91 91
...@@ -129,8 +129,8 @@ ep-report:ReportAliasIdentifier ...@@ -129,8 +129,8 @@ ep-report:ReportAliasIdentifier
129 rdfs:subClassOf owl:Thing ; 129 rdfs:subClassOf owl:Thing ;
130 rdfs:subClassOf 130 rdfs:subClassOf
131 [ rdf:type owl:Restriction ; 131 [ rdf:type owl:Restriction ;
132 - owl:minCardinality "1"^^xsd:nonNegativeInteger ; 132 + owl:cardinality "1"^^xsd:nonNegativeInteger ;
133 - owl:onProperty ep-report:aliasName 133 + owl:onProperty ep-report:isAliasFor
134 ] ; 134 ] ;
135 rdfs:subClassOf 135 rdfs:subClassOf
136 [ rdf:type owl:Restriction ; 136 [ rdf:type owl:Restriction ;
...@@ -139,17 +139,17 @@ ep-report:ReportAliasIdentifier ...@@ -139,17 +139,17 @@ ep-report:ReportAliasIdentifier
139 ] ; 139 ] ;
140 rdfs:subClassOf 140 rdfs:subClassOf
141 [ rdf:type owl:Restriction ; 141 [ rdf:type owl:Restriction ;
142 - owl:cardinality "1"^^xsd:nonNegativeInteger ; 142 + owl:minCardinality "1"^^xsd:nonNegativeInteger ;
143 - owl:onProperty ep-report:isAliasFor 143 + owl:onProperty ep-report:aliasName
144 ] . 144 ] .
145 145
146 ep-report:ReportForInstant 146 ep-report:ReportForInstant
147 - rdf:type owl:Class , ep-report:ReportPeriodType ; 147 + rdf:type ep-report:ReportPeriodType , owl:Class ;
148 rdfs:label "report for instant"^^xsd:string ; 148 rdfs:label "report for instant"^^xsd:string ;
149 rdfs:subClassOf ep-report:Report . 149 rdfs:subClassOf ep-report:Report .
150 150
151 ep-report:ReportMonthToDate 151 ep-report:ReportMonthToDate
152 - rdf:type owl:Class , ep-report:ReportPeriodType ; 152 + rdf:type ep-report:ReportPeriodType , owl:Class ;
153 rdfs:label "report month to date"^^xsd:string ; 153 rdfs:label "report month to date"^^xsd:string ;
154 rdfs:subClassOf ep-report:Report . 154 rdfs:subClassOf ep-report:Report .
155 155
...@@ -159,7 +159,7 @@ ep-report:ReportPeriodType ...@@ -159,7 +159,7 @@ ep-report:ReportPeriodType
159 rdfs:subClassOf owl:Class . 159 rdfs:subClassOf owl:Class .
160 160
161 ep-report:ReportYearToDate 161 ep-report:ReportYearToDate
162 - rdf:type owl:Class , ep-report:ReportPeriodType ; 162 + rdf:type ep-report:ReportPeriodType , owl:Class ;
163 rdfs:label "report year to date"^^xsd:string ; 163 rdfs:label "report year to date"^^xsd:string ;
164 rdfs:subClassOf ep-report:Report . 164 rdfs:subClassOf ep-report:Report .
165 165
...@@ -168,27 +168,27 @@ ep-report:WeeklyDrillingReport ...@@ -168,27 +168,27 @@ ep-report:WeeklyDrillingReport
168 rdfs:subClassOf ep-report:Report ; 168 rdfs:subClassOf ep-report:Report ;
169 rdfs:subClassOf 169 rdfs:subClassOf
170 [ rdf:type owl:Restriction ; 170 [ rdf:type owl:Restriction ;
171 - owl:allValuesFrom ep-report:DailyDrillingReport ; 171 + owl:cardinality "1"^^xsd:nonNegativeInteger ;
172 - owl:onProperty ep-report:reportOn 172 + owl:onProperty ep-report:createdAt
173 ] ; 173 ] ;
174 rdfs:subClassOf 174 rdfs:subClassOf
175 [ rdf:type owl:Restriction ; 175 [ rdf:type owl:Restriction ;
176 - owl:cardinality "7"^^xsd:nonNegativeInteger ; 176 + owl:allValuesFrom xsd:dateTime ;
177 - owl:onProperty ep-report:reportOn 177 + owl:onProperty ep-report:createdAt
178 ] ; 178 ] ;
179 rdfs:subClassOf 179 rdfs:subClassOf
180 [ rdf:type owl:Restriction ; 180 [ rdf:type owl:Restriction ;
181 - owl:allValuesFrom xsd:dateTime ; 181 + owl:cardinality "7"^^xsd:nonNegativeInteger ;
182 - owl:onProperty ep-report:createdAt 182 + owl:onProperty ep-report:reportOn
183 ] ; 183 ] ;
184 rdfs:subClassOf 184 rdfs:subClassOf
185 [ rdf:type owl:Restriction ; 185 [ rdf:type owl:Restriction ;
186 - owl:cardinality "1"^^xsd:nonNegativeInteger ; 186 + owl:allValuesFrom ep-report:DailyDrillingReport ;
187 - owl:onProperty ep-report:createdAt 187 + owl:onProperty ep-report:reportOn
188 ] . 188 ] .
189 189
190 ep-report:WeeklyReport 190 ep-report:WeeklyReport
191 - rdf:type owl:Class , ep-report:ReportPeriodType ; 191 + rdf:type ep-report:ReportPeriodType , owl:Class ;
192 rdfs:label "weekly report"^^xsd:string ; 192 rdfs:label "weekly report"^^xsd:string ;
193 rdfs:subClassOf ep-report:Report . 193 rdfs:subClassOf ep-report:Report .
194 194
...@@ -198,7 +198,7 @@ ep-report:WellTestReport ...@@ -198,7 +198,7 @@ ep-report:WellTestReport
198 rdfs:subClassOf ep-report:Report . 198 rdfs:subClassOf ep-report:Report .
199 199
200 ep-report:YearlyReport 200 ep-report:YearlyReport
201 - rdf:type owl:Class , ep-report:ReportPeriodType ; 201 + rdf:type ep-report:ReportPeriodType , owl:Class ;
202 rdfs:label "yearly report"^^xsd:string ; 202 rdfs:label "yearly report"^^xsd:string ;
203 rdfs:subClassOf ep-report:Report . 203 rdfs:subClassOf ep-report:Report .
204 204
...@@ -211,12 +211,12 @@ ep-report:aliasOwner ...@@ -211,12 +211,12 @@ ep-report:aliasOwner
211 rdfs:range <http://www.reportinghub.no/np/schema/npd#Individual> . 211 rdfs:range <http://www.reportinghub.no/np/schema/npd#Individual> .
212 212
213 ep-report:createdAt 213 ep-report:createdAt
214 - rdf:type owl:DatatypeProperty , owl:FunctionalProperty ; 214 + rdf:type owl:FunctionalProperty , owl:DatatypeProperty ;
215 rdfs:domain ep-report:Report ; 215 rdfs:domain ep-report:Report ;
216 rdfs:label "created at"^^xsd:string . 216 rdfs:label "created at"^^xsd:string .
217 217
218 ep-report:dailyDrillingReportNumber 218 ep-report:dailyDrillingReportNumber
219 - rdf:type owl:DatatypeProperty , owl:FunctionalProperty ; 219 + rdf:type owl:FunctionalProperty , owl:DatatypeProperty ;
220 rdfs:domain ep-report:DailyDrillingReport ; 220 rdfs:domain ep-report:DailyDrillingReport ;
221 rdfs:label "daily drilling report number"^^xsd:string . 221 rdfs:label "daily drilling report number"^^xsd:string .
222 222
...@@ -241,7 +241,7 @@ ep-report:disclaimer ...@@ -241,7 +241,7 @@ ep-report:disclaimer
241 rdfs:range xsd:string . 241 rdfs:range xsd:string .
242 242
243 ep-report:hasContent 243 ep-report:hasContent
244 - rdf:type owl:DatatypeProperty , owl:FunctionalProperty ; 244 + rdf:type owl:FunctionalProperty , owl:DatatypeProperty ;
245 rdfs:domain ep-report:Report ; 245 rdfs:domain ep-report:Report ;
246 rdfs:label "has content"^^xsd:string . 246 rdfs:label "has content"^^xsd:string .
247 247
...@@ -250,12 +250,12 @@ ep-report:isAliasFor ...@@ -250,12 +250,12 @@ ep-report:isAliasFor
250 rdfs:range <http://www.reportinghub.no/np/schema/npd#Individual> . 250 rdfs:range <http://www.reportinghub.no/np/schema/npd#Individual> .
251 251
252 ep-report:issuedAt 252 ep-report:issuedAt
253 - rdf:type owl:DatatypeProperty , owl:FunctionalProperty ; 253 + rdf:type owl:FunctionalProperty , owl:DatatypeProperty ;
254 rdfs:domain ep-report:Report ; 254 rdfs:domain ep-report:Report ;
255 rdfs:label "issued at"^^xsd:string . 255 rdfs:label "issued at"^^xsd:string .
256 256
257 ep-report:nameAsDatumObject 257 ep-report:nameAsDatumObject
258 - rdf:type owl:DatatypeProperty , owl:FunctionalProperty ; 258 + rdf:type owl:FunctionalProperty , owl:DatatypeProperty ;
259 rdfs:domain <http://www.reportinghub.no/ep/schema/core#PhysicalObject> ; 259 rdfs:domain <http://www.reportinghub.no/ep/schema/core#PhysicalObject> ;
260 rdfs:label "name as datum object"^^xsd:string . 260 rdfs:label "name as datum object"^^xsd:string .
261 261
...@@ -263,3 +263,9 @@ ep-report:reportOn ...@@ -263,3 +263,9 @@ ep-report:reportOn
263 rdf:type owl:ObjectProperty ; 263 rdf:type owl:ObjectProperty ;
264 rdfs:domain ep-report:Report ; 264 rdfs:domain ep-report:Report ;
265 rdfs:label "report on"^^xsd:string . 265 rdfs:label "report on"^^xsd:string .
266 +
267 +ep-report:reportSubmittedBy
268 + rdf:type owl:FunctionalProperty , owl:ObjectProperty ;
269 + rdfs:domain ep-report:Report ;
270 + rdfs:label "report submitted by"^^xsd:string ;
271 + rdfs:range <http://www.reportinghub.no/ep/schema/core#PhysicalObject> .
......
...@@ -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 10001a Create the inteval identifier - dateStart and dateEnd from context"^^xsd:string ; 23 + rdfs:comment "STEP 10001b Create the interval identifier - date and dateEnd from context"^^xsd:string ;
24 sp:templates ([ sp:object 24 sp:templates ([ sp:object
25 [ sp:varName "intervalIdentifier"^^xsd:string 25 [ sp:varName "intervalIdentifier"^^xsd:string
26 ] ; 26 ] ;
...@@ -38,12 +38,21 @@ ...@@ -38,12 +38,21 @@
38 [ sp:varName "contextRef"^^xsd:string 38 [ sp:varName "contextRef"^^xsd:string
39 ] 39 ]
40 ] [ sp:object 40 ] [ sp:object
41 - [ sp:varName "dateStart"^^xsd:string 41 + [ sp:varName "date"^^xsd:string
42 ] ; 42 ] ;
43 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ; 43 + sp:predicate <http://www.epim.no/schemas/mprml/1#date> ;
44 sp:subject 44 sp:subject
45 [ sp:varName "contextRef"^^xsd:string 45 [ sp:varName "contextRef"^^xsd:string
46 ] 46 ]
47 + ] [ rdf:type sp:NotExists ;
48 + sp:elements ([ sp:object
49 + [ sp:varName "dateStart"^^xsd:string
50 + ] ;
51 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
52 + sp:subject
53 + [ sp:varName "contextRef"^^xsd:string
54 + ]
55 + ])
47 ] [ sp:object 56 ] [ sp:object
48 [ sp:varName "dateEnd"^^xsd:string 57 [ sp:varName "dateEnd"^^xsd:string
49 ] ; 58 ] ;
...@@ -54,7 +63,7 @@ ...@@ -54,7 +63,7 @@
54 ] [ rdf:type sp:Bind ; 63 ] [ rdf:type sp:Bind ;
55 sp:expression 64 sp:expression
56 [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ; 65 [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ;
57 - sp:arg1 [ sp:varName "dateStart"^^xsd:string 66 + sp:arg1 [ sp:varName "date"^^xsd:string
58 ] ; 67 ] ;
59 sp:arg2 [ sp:varName "dateEnd"^^xsd:string 68 sp:arg2 [ sp:varName "dateEnd"^^xsd:string
60 ] 69 ]
...@@ -66,124 +75,66 @@ ...@@ -66,124 +75,66 @@
66 ] ; 75 ] ;
67 spin:rule 76 spin:rule
68 [ rdf:type sp:Construct ; 77 [ rdf:type sp:Construct ;
69 - rdfs:comment "STEP 10001p Create the ProductionReport - no installation"^^xsd:string ; 78 + rdfs:comment "STEP 10001a Create the inteval identifier - dateStart and dateEnd from context"^^xsd:string ;
70 - sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ; 79 + sp:templates ([ sp:object
80 + [ sp:varName "intervalIdentifier"^^xsd:string
81 + ] ;
82 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
83 + sp:subject spin:_this
84 + ]) ;
85 + sp:where ([ sp:object
86 + [ sp:varName "contextRef"^^xsd:string
87 + ] ;
88 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
89 + sp:subject spin:_this
90 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
71 sp:predicate rdf:type ; 91 sp:predicate rdf:type ;
72 sp:subject 92 sp:subject
73 - [ sp:varName "productionReport"^^xsd:string 93 + [ sp:varName "contextRef"^^xsd:string
74 - ]
75 - ] [ sp:object _:b1 ;
76 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ;
77 - sp:subject
78 - [ sp:varName "productionReport"^^xsd:string
79 ] 94 ]
80 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ; 95 + ] [ sp:object
81 - sp:predicate rdf:type ; 96 + [ sp:varName "dateStart"^^xsd:string
82 - sp:subject _:b1 97 + ] ;
83 - ] [ sp:object spin:_this ; 98 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
84 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
85 sp:subject 99 sp:subject
86 - [ sp:varName "productionReport"^^xsd:string 100 + [ sp:varName "contextRef"^^xsd:string
87 ] 101 ]
88 ] [ sp:object 102 ] [ sp:object
89 - [ sp:varName "contextRef"^^xsd:string 103 + [ sp:varName "dateEnd"^^xsd:string
90 - ] ;
91 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
92 - sp:subject _:b1
93 - ]) ;
94 - sp:where ([ sp:object
95 - [ sp:varName "intervalIdentifier"^^xsd:string
96 - ] ;
97 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
98 - sp:subject spin:_this
99 - ] [ rdf:type sp:NotExists ;
100 - sp:elements ([ sp:object
101 - [ sp:varName "productVolumeRef"^^xsd:string
102 - ] ;
103 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
104 - sp:subject spin:_this
105 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
106 - sp:predicate rdf:type ;
107 - sp:subject
108 - [ sp:varName "productVolumeRef"^^xsd:string
109 - ]
110 - ] [ sp:object
111 - [ sp:varName "something"^^xsd:string
112 - ] ;
113 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
114 - sp:subject
115 - [ sp:varName "productVolumeRef"^^xsd:string
116 - ]
117 - ])
118 - ] [ rdf:type sp:NotExists ;
119 - sp:elements ([ sp:object
120 - [ sp:varName "productionOperationRef"^^xsd:string
121 - ] ;
122 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
123 - sp:subject spin:_this
124 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productionOperation> ;
125 - sp:predicate rdf:type ;
126 - sp:subject
127 - [ sp:varName "productionOperationRef"^^xsd:string
128 - ]
129 - ] [ sp:object
130 - [ sp:varName "somethingElse"^^xsd:string
131 - ] ;
132 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
133 - sp:subject
134 - [ sp:varName "productionOperationRef"^^xsd:string
135 - ]
136 - ])
137 - ] [ rdf:type sp:NotExists ;
138 - sp:elements ([ sp:object
139 - [ sp:varName "contextRef"^^xsd:string
140 - ] ;
141 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
142 - sp:subject spin:_this
143 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
144 - sp:predicate rdf:type ;
145 - sp:subject
146 - [ sp:varName "contextRef"^^xsd:string
147 - ]
148 - ] [ sp:object
149 - [ sp:varName "somethingElseElse"^^xsd:string
150 - ] ;
151 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
152 - sp:subject
153 - [ sp:varName "contextRef"^^xsd:string
154 - ]
155 - ])
156 - ] [ rdf:type sp:Bind ;
157 - sp:expression
158 - [ rdf:type ep-spin-lib:normalizeString ;
159 - sp:arg1 "noInstallation"
160 ] ; 104 ] ;
161 - sp:variable 105 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
162 - [ sp:varName "normalizedName"^^xsd:string 106 + sp:subject
107 + [ sp:varName "contextRef"^^xsd:string
163 ] 108 ]
164 ] [ rdf:type sp:Bind ; 109 ] [ rdf:type sp:Bind ;
165 sp:expression 110 sp:expression
166 - [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ; 111 + [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ;
167 - sp:arg1 [ sp:varName "normalizedName"^^xsd:string 112 + sp:arg1 [ sp:varName "dateStart"^^xsd:string
168 ] ; 113 ] ;
169 - sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string 114 + sp:arg2 [ sp:varName "dateEnd"^^xsd:string
170 ] 115 ]
171 ] ; 116 ] ;
172 sp:variable 117 sp:variable
173 - [ sp:varName "productionReport"^^xsd:string 118 + [ sp:varName "intervalIdentifier"^^xsd:string
174 ] 119 ]
175 ]) 120 ])
176 ] ; 121 ] ;
177 spin:rule 122 spin:rule
178 [ rdf:type sp:Construct ; 123 [ rdf:type sp:Construct ;
179 - rdfs:comment "STEP 10010 Add the contextFacility"^^xsd:string ; 124 + rdfs:comment "STEP 10020 Add the operator"^^xsd:string ;
180 - sp:templates ([ sp:object 125 + sp:templates ([ sp:object _:b1 ;
181 - [ sp:varName "contextFacility"^^xsd:string 126 + sp:predicate <http://www.reportinghub.no/ep/schema/facility#facilityOperator> ;
182 - ] ;
183 - sp:predicate <http://www.reportinghub.no/ep/schema/geography#locatedWithin> ;
184 sp:subject 127 sp:subject
185 - [ sp:varName "productionFacility"^^xsd:string 128 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
186 ] 129 ]
130 + ] [ sp:object <http://www.reportinghub.no/ep/schema/organization#Organization> ;
131 + sp:predicate rdf:type ;
132 + sp:subject _:b1
133 + ] [ sp:object
134 + [ sp:varName "operator"^^xsd:string
135 + ] ;
136 + sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
137 + sp:subject _:b1
187 ]) ; 138 ]) ;
188 sp:where ([ sp:object 139 sp:where ([ sp:object
189 [ sp:varName "contextRef"^^xsd:string 140 [ sp:varName "contextRef"^^xsd:string
...@@ -196,18 +147,18 @@ ...@@ -196,18 +147,18 @@
196 [ sp:varName "contextRef"^^xsd:string 147 [ sp:varName "contextRef"^^xsd:string
197 ] 148 ]
198 ] [ sp:object 149 ] [ sp:object
199 - [ sp:varName "contectFacilityRef"^^xsd:string 150 + [ sp:varName "operatorRef"^^xsd:string
200 ] ; 151 ] ;
201 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ; 152 + sp:predicate <http://www.epim.no/schemas/mprml/1#operatorRef> ;
202 sp:subject 153 sp:subject
203 [ sp:varName "contextRef"^^xsd:string 154 [ sp:varName "contextRef"^^xsd:string
204 ] 155 ]
205 ] [ sp:object 156 ] [ sp:object
206 - [ sp:varName "contextFacilityRef"^^xsd:string 157 + [ sp:varName "operatorRef"^^xsd:string
207 ] ; 158 ] ;
208 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 159 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
209 sp:subject 160 sp:subject
210 - [ sp:varName "contextFacility"^^xsd:string 161 + [ sp:varName "operator"^^xsd:string
211 ] 162 ]
212 ] [ sp:object spin:_this ; 163 ] [ sp:object spin:_this ;
213 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 164 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
...@@ -226,20 +177,13 @@ ...@@ -226,20 +177,13 @@
226 sp:subject 177 sp:subject
227 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string 178 [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
228 ] 179 ]
229 - ] [ sp:object
230 - [ sp:varName "productionFacility"^^xsd:string
231 - ] ;
232 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
233 - sp:subject
234 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
235 - ]
236 ]) 180 ])
237 ] ; 181 ] ;
238 spin:rule 182 spin:rule
239 [ rdf:type sp:Construct ; 183 [ rdf:type sp:Construct ;
240 - rdfs:comment "STEP 10001b Create the interval identifier - date and dateEnd from context"^^xsd:string ; 184 + rdfs:comment "STEP 10001c Create the interval identifier - date from context"^^xsd:string ;
241 sp:templates ([ sp:object 185 sp:templates ([ sp:object
242 - [ sp:varName "intervalIdentifier"^^xsd:string 186 + [ sp:varName "date"^^xsd:string
243 ] ; 187 ] ;
244 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 188 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
245 sp:subject spin:_this 189 sp:subject spin:_this
...@@ -270,43 +214,69 @@ ...@@ -270,43 +214,69 @@
270 [ sp:varName "contextRef"^^xsd:string 214 [ sp:varName "contextRef"^^xsd:string
271 ] 215 ]
272 ]) 216 ])
273 - ] [ sp:object 217 + ] [ rdf:type sp:NotExists ;
274 - [ sp:varName "dateEnd"^^xsd:string 218 + sp:elements ([ sp:object
275 - ] ; 219 + [ sp:varName "dateEnd"^^xsd:string
276 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ; 220 + ] ;
277 - sp:subject 221 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
278 - [ sp:varName "contextRef"^^xsd:string 222 + sp:subject
279 - ] 223 + [ sp:varName "contextRef"^^xsd:string
280 - ] [ rdf:type sp:Bind ; 224 + ]
281 - sp:expression 225 + ])
282 - [ rdf:type ep-mpr-spin-lib:buildIntervalIdentifier ;
283 - sp:arg1 [ sp:varName "date"^^xsd:string
284 - ] ;
285 - sp:arg2 [ sp:varName "dateEnd"^^xsd:string
286 - ]
287 - ] ;
288 - sp:variable
289 - [ sp:varName "intervalIdentifier"^^xsd:string
290 - ]
291 ]) 226 ])
292 ] ; 227 ] ;
293 spin:rule 228 spin:rule
294 [ rdf:type sp:Construct ; 229 [ rdf:type sp:Construct ;
295 - rdfs:comment "STEP 10001z Add the issue date and title"^^xsd:string ; 230 + rdfs:comment "STEP 10001d Create the interval identifier - dateEnd from context"^^xsd:string ;
296 sp:templates ([ sp:object 231 sp:templates ([ sp:object
297 - [ sp:varName "month"^^xsd:string 232 + [ sp:varName "dateEnd"^^xsd:string
298 ] ; 233 ] ;
299 - sp:predicate <http://www.reportinghub.no/ep/schema/report#issuedAt> ; 234 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
235 + sp:subject spin:_this
236 + ]) ;
237 + sp:where ([ sp:object
238 + [ sp:varName "contextRef"^^xsd:string
239 + ] ;
240 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
241 + sp:subject spin:_this
242 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
243 + sp:predicate rdf:type ;
300 sp:subject 244 sp:subject
301 - [ sp:varName "productionReport"^^xsd:string 245 + [ sp:varName "contextRef"^^xsd:string
302 ] 246 ]
303 ] [ sp:object 247 ] [ sp:object
304 - [ sp:varName "title"^^xsd:string 248 + [ sp:varName "dateEnd"^^xsd:string
305 ] ; 249 ] ;
306 - sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ; 250 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
307 sp:subject 251 sp:subject
308 - [ sp:varName "productionReport"^^xsd:string 252 + [ sp:varName "contextRef"^^xsd:string
309 ] 253 ]
254 + ] [ rdf:type sp:NotExists ;
255 + sp:elements ([ sp:object
256 + [ sp:varName "date"^^xsd:string
257 + ] ;
258 + sp:predicate <http://www.epim.no/schemas/mprml/1#date> ;
259 + sp:subject
260 + [ sp:varName "contextRef"^^xsd:string
261 + ]
262 + ])
263 + ] [ rdf:type sp:NotExists ;
264 + sp:elements ([ sp:object
265 + [ sp:varName "dateStart"^^xsd:string
266 + ] ;
267 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
268 + sp:subject
269 + [ sp:varName "contextRef"^^xsd:string
270 + ]
271 + ])
272 + ])
273 + ] ;
274 + spin:rule
275 + [ rdf:type sp:Construct ;
276 + rdfs:comment "STEP 10001e Create the interval identifier - no date"^^xsd:string ;
277 + sp:templates ([ sp:object "noDate" ;
278 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
279 + sp:subject spin:_this
310 ]) ; 280 ]) ;
311 sp:where ([ sp:object 281 sp:where ([ sp:object
312 [ sp:varName "contextRef"^^xsd:string 282 [ sp:varName "contextRef"^^xsd:string
...@@ -318,48 +288,40 @@ ...@@ -318,48 +288,40 @@
318 sp:subject 288 sp:subject
319 [ sp:varName "contextRef"^^xsd:string 289 [ sp:varName "contextRef"^^xsd:string
320 ] 290 ]
321 - ] [ rdf:type sp:Optional ; 291 + ] [ rdf:type sp:NotExists ;
322 sp:elements ([ sp:object 292 sp:elements ([ sp:object
323 - [ sp:varName "month"^^xsd:string 293 + [ sp:varName "dateEnd"^^xsd:string
324 ] ; 294 ] ;
325 - sp:predicate <http://www.epim.no/schemas/mprml/1#month> ; 295 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
326 sp:subject 296 sp:subject
327 [ sp:varName "contextRef"^^xsd:string 297 [ sp:varName "contextRef"^^xsd:string
328 ] 298 ]
329 ]) 299 ])
330 - ] [ rdf:type sp:Optional ; 300 + ] [ rdf:type sp:NotExists ;
331 sp:elements ([ sp:object 301 sp:elements ([ sp:object
332 - [ sp:varName "titleRef"^^xsd:string 302 + [ sp:varName "date"^^xsd:string
333 ] ; 303 ] ;
334 - sp:predicate <http://www.epim.no/schemas/mprml/1#titleRef> ; 304 + sp:predicate <http://www.epim.no/schemas/mprml/1#date> ;
335 sp:subject 305 sp:subject
336 [ sp:varName "contextRef"^^xsd:string 306 [ sp:varName "contextRef"^^xsd:string
337 ] 307 ]
338 - ] [ sp:object 308 + ])
339 - [ sp:varName "title"^^xsd:string 309 + ] [ rdf:type sp:NotExists ;
310 + sp:elements ([ sp:object
311 + [ sp:varName "dateStart"^^xsd:string
340 ] ; 312 ] ;
341 - sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ; 313 + sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
342 sp:subject 314 sp:subject
343 - [ sp:varName "titleRef"^^xsd:string 315 + [ sp:varName "contextRef"^^xsd:string
344 ] 316 ]
345 ]) 317 ])
346 - ] [ sp:object spin:_this ;
347 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
348 - sp:subject
349 - [ sp:varName "productionReport"^^xsd:string
350 - ]
351 ]) 318 ])
352 ] ; 319 ] ;
353 spin:rule 320 spin:rule
354 [ rdf:type sp:Construct ; 321 [ rdf:type sp:Construct ;
355 - rdfs:comment "STEP 10001o Create the ProductionReport - extract the name from productVolume/installation"^^xsd:string ; 322 + rdfs:comment "STEP 10001n Set the submitting installation"^^xsd:string ;
356 - sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ; 323 + sp:templates ([ sp:object _:b2 ;
357 - sp:predicate rdf:type ; 324 + sp:predicate <http://www.reportinghub.no/ep/schema/report#reportSubmittedBy> ;
358 - sp:subject
359 - [ sp:varName "productionReport"^^xsd:string
360 - ]
361 - ] [ sp:object _:b2 ;
362 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ;
363 sp:subject 325 sp:subject
364 [ sp:varName "productionReport"^^xsd:string 326 [ sp:varName "productionReport"^^xsd:string
365 ] 327 ]
...@@ -371,38 +333,28 @@ ...@@ -371,38 +333,28 @@
371 ] ; 333 ] ;
372 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 334 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
373 sp:subject _:b2 335 sp:subject _:b2
336 + ]) ;
337 + sp:where ([ sp:object
338 + [ sp:varName "contextRef"^^xsd:string
339 + ] ;
340 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
341 + sp:subject spin:_this
374 ] [ sp:object spin:_this ; 342 ] [ sp:object spin:_this ;
375 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 343 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
376 sp:subject 344 sp:subject
377 [ sp:varName "productionReport"^^xsd:string 345 [ sp:varName "productionReport"^^xsd:string
378 ] 346 ]
379 - ] [ sp:object 347 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
380 - [ sp:varName "contextRef"^^xsd:string
381 - ] ;
382 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
383 - sp:subject _:b2
384 - ]) ;
385 - sp:where ([ sp:object
386 - [ sp:varName "intervalIdentifier"^^xsd:string
387 - ] ;
388 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
389 - sp:subject spin:_this
390 - ] [ sp:object
391 - [ sp:varName "productVolumeRef"^^xsd:string
392 - ] ;
393 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
394 - sp:subject spin:_this
395 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
396 sp:predicate rdf:type ; 348 sp:predicate rdf:type ;
397 sp:subject 349 sp:subject
398 - [ sp:varName "productVolumeRef"^^xsd:string 350 + [ sp:varName "contextRef"^^xsd:string
399 ] 351 ]
400 ] [ sp:object 352 ] [ sp:object
401 [ sp:varName "installationRef"^^xsd:string 353 [ sp:varName "installationRef"^^xsd:string
402 ] ; 354 ] ;
403 sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ; 355 sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
404 sp:subject 356 sp:subject
405 - [ sp:varName "productVolumeRef"^^xsd:string 357 + [ sp:varName "contextRef"^^xsd:string
406 ] 358 ]
407 ] [ sp:object 359 ] [ sp:object
408 [ sp:varName "installationRef"^^xsd:string 360 [ sp:varName "installationRef"^^xsd:string
...@@ -411,176 +363,25 @@ ...@@ -411,176 +363,25 @@
411 sp:subject 363 sp:subject
412 [ sp:varName "installation"^^xsd:string 364 [ sp:varName "installation"^^xsd:string
413 ] 365 ]
414 - ] [ rdf:type sp:NotExists ;
415 - sp:elements ([ sp:object
416 - [ sp:varName "productionOperationRef"^^xsd:string
417 - ] ;
418 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
419 - sp:subject spin:_this
420 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productionOperation> ;
421 - sp:predicate rdf:type ;
422 - sp:subject
423 - [ sp:varName "productionOperationRef"^^xsd:string
424 - ]
425 - ] [ sp:object
426 - [ sp:varName "something"^^xsd:string
427 - ] ;
428 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
429 - sp:subject
430 - [ sp:varName "productionOperationRef"^^xsd:string
431 - ]
432 - ])
433 - ] [ rdf:type sp:NotExists ;
434 - sp:elements ([ sp:object
435 - [ sp:varName "contextRef"^^xsd:string
436 - ] ;
437 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
438 - sp:subject spin:_this
439 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
440 - sp:predicate rdf:type ;
441 - sp:subject
442 - [ sp:varName "contextRef"^^xsd:string
443 - ]
444 - ] [ sp:object
445 - [ sp:varName "somethingElse"^^xsd:string
446 - ] ;
447 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
448 - sp:subject
449 - [ sp:varName "contextRef"^^xsd:string
450 - ]
451 - ])
452 - ] [ rdf:type sp:Bind ;
453 - sp:expression
454 - [ rdf:type spl:object ;
455 - sp:arg1 [ sp:varName "installationRef"^^xsd:string
456 - ] ;
457 - sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText>
458 - ] ;
459 - sp:variable
460 - [ sp:varName "normalizedInstallationName"^^xsd:string
461 - ]
462 - ] [ rdf:type sp:Bind ;
463 - sp:expression
464 - [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ;
465 - sp:arg1 [ sp:varName "normalizedInstallationName"^^xsd:string
466 - ] ;
467 - sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string
468 - ]
469 - ] ;
470 - sp:variable
471 - [ sp:varName "productionReport"^^xsd:string
472 - ]
473 ]) 366 ])
474 ] ; 367 ] ;
475 spin:rule 368 spin:rule
476 [ rdf:type sp:Construct ; 369 [ rdf:type sp:Construct ;
477 - rdfs:comment "STEP 10001n Create the ProductionReport - extract the name from productionOperation/installation"^^xsd:string ; 370 + rdfs:comment "STEP 10001z Add the issue date and title"^^xsd:string ;
478 - sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ; 371 + sp:templates ([ sp:object
479 - sp:predicate rdf:type ; 372 + [ sp:varName "month"^^xsd:string
480 - sp:subject
481 - [ sp:varName "productionReport"^^xsd:string
482 - ]
483 - ] [ sp:object _:b3 ;
484 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ;
485 - sp:subject
486 - [ sp:varName "productionReport"^^xsd:string
487 - ]
488 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
489 - sp:predicate rdf:type ;
490 - sp:subject _:b3
491 - ] [ sp:object
492 - [ sp:varName "installation"^^xsd:string
493 ] ; 373 ] ;
494 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 374 + sp:predicate <http://www.reportinghub.no/ep/schema/report#issuedAt> ;
495 - sp:subject _:b3
496 - ] [ sp:object spin:_this ;
497 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
498 sp:subject 375 sp:subject
499 [ sp:varName "productionReport"^^xsd:string 376 [ sp:varName "productionReport"^^xsd:string
500 ] 377 ]
501 ] [ sp:object 378 ] [ sp:object
502 - [ sp:varName "contextRef"^^xsd:string 379 + [ sp:varName "title"^^xsd:string
503 - ] ;
504 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
505 - sp:subject _:b3
506 - ]) ;
507 - sp:where ([ sp:object
508 - [ sp:varName "intervalIdentifier"^^xsd:string
509 - ] ;
510 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
511 - sp:subject spin:_this
512 - ] [ sp:object
513 - [ sp:varName "productionOperationRef"^^xsd:string
514 - ] ;
515 - sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
516 - sp:subject spin:_this
517 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productionOperation> ;
518 - sp:predicate rdf:type ;
519 - sp:subject
520 - [ sp:varName "productionOperationRef"^^xsd:string
521 - ]
522 - ] [ sp:object
523 - [ sp:varName "installationRef"^^xsd:string
524 - ] ;
525 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
526 - sp:subject
527 - [ sp:varName "productionOperationRef"^^xsd:string
528 - ]
529 - ] [ sp:object
530 - [ sp:varName "installationRef"^^xsd:string
531 ] ; 380 ] ;
532 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 381 + sp:predicate <http://www.reportinghub.no/ep/schema/core#name> ;
533 sp:subject 382 sp:subject
534 - [ sp:varName "installation"^^xsd:string
535 - ]
536 - ] [ rdf:type sp:NotExists ;
537 - sp:elements ([ sp:object
538 - [ sp:varName "contextRef"^^xsd:string
539 - ] ;
540 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
541 - sp:subject spin:_this
542 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
543 - sp:predicate rdf:type ;
544 - sp:subject
545 - [ sp:varName "contextRef"^^xsd:string
546 - ]
547 - ] [ sp:object
548 - [ sp:varName "something"^^xsd:string
549 - ] ;
550 - sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
551 - sp:subject
552 - [ sp:varName "contextRef"^^xsd:string
553 - ]
554 - ])
555 - ] [ rdf:type sp:Bind ;
556 - sp:expression
557 - [ rdf:type spl:object ;
558 - sp:arg1 [ sp:varName "installationRef"^^xsd:string
559 - ] ;
560 - sp:arg2 <http://www.reportinghub.no/ep/transform/transform-helper-schema#hasDerivedText>
561 - ] ;
562 - sp:variable
563 - [ sp:varName "normalizedInstallationName"^^xsd:string
564 - ]
565 - ] [ rdf:type sp:Bind ;
566 - sp:expression
567 - [ rdf:type ep-mpr-spin-lib:buildProductionReportURI ;
568 - sp:arg1 [ sp:varName "normalizedInstallationName"^^xsd:string
569 - ] ;
570 - sp:arg2 [ sp:varName "intervalIdentifier"^^xsd:string
571 - ]
572 - ] ;
573 - sp:variable
574 [ sp:varName "productionReport"^^xsd:string 383 [ sp:varName "productionReport"^^xsd:string
575 ] 384 ]
576 - ])
577 - ] ;
578 - spin:rule
579 - [ rdf:type sp:Construct ;
580 - rdfs:comment "STEP 10001e Create the interval identifier - no date"^^xsd:string ;
581 - sp:templates ([ sp:object "noDate" ;
582 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
583 - sp:subject spin:_this
584 ]) ; 385 ]) ;
585 sp:where ([ sp:object 386 sp:where ([ sp:object
586 [ sp:varName "contextRef"^^xsd:string 387 [ sp:varName "contextRef"^^xsd:string
...@@ -592,43 +393,48 @@ ...@@ -592,43 +393,48 @@
592 sp:subject 393 sp:subject
593 [ sp:varName "contextRef"^^xsd:string 394 [ sp:varName "contextRef"^^xsd:string
594 ] 395 ]
595 - ] [ rdf:type sp:NotExists ; 396 + ] [ rdf:type sp:Optional ;
596 sp:elements ([ sp:object 397 sp:elements ([ sp:object
597 - [ sp:varName "dateEnd"^^xsd:string 398 + [ sp:varName "month"^^xsd:string
598 ] ; 399 ] ;
599 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ; 400 + sp:predicate <http://www.epim.no/schemas/mprml/1#month> ;
600 sp:subject 401 sp:subject
601 [ sp:varName "contextRef"^^xsd:string 402 [ sp:varName "contextRef"^^xsd:string
602 ] 403 ]
603 ]) 404 ])
604 - ] [ rdf:type sp:NotExists ; 405 + ] [ rdf:type sp:Optional ;
605 sp:elements ([ sp:object 406 sp:elements ([ sp:object
606 - [ sp:varName "date"^^xsd:string 407 + [ sp:varName "titleRef"^^xsd:string
607 ] ; 408 ] ;
608 - sp:predicate <http://www.epim.no/schemas/mprml/1#date> ; 409 + sp:predicate <http://www.epim.no/schemas/mprml/1#titleRef> ;
609 sp:subject 410 sp:subject
610 [ sp:varName "contextRef"^^xsd:string 411 [ sp:varName "contextRef"^^xsd:string
611 ] 412 ]
612 - ]) 413 + ] [ sp:object
613 - ] [ rdf:type sp:NotExists ; 414 + [ sp:varName "title"^^xsd:string
614 - sp:elements ([ sp:object
615 - [ sp:varName "dateStart"^^xsd:string
616 ] ; 415 ] ;
617 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ; 416 + sp:predicate <http://www.linkedmodel.org/schema/dtype#value> ;
618 sp:subject 417 sp:subject
619 - [ sp:varName "contextRef"^^xsd:string 418 + [ sp:varName "titleRef"^^xsd:string
620 ] 419 ]
621 ]) 420 ])
421 + ] [ sp:object spin:_this ;
422 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
423 + sp:subject
424 + [ sp:varName "productionReport"^^xsd:string
425 + ]
622 ]) 426 ])
623 ] ; 427 ] ;
624 spin:rule 428 spin:rule
625 [ rdf:type sp:Construct ; 429 [ rdf:type sp:Construct ;
626 - rdfs:comment "STEP 10001c Create the interval identifier - date from context"^^xsd:string ; 430 + rdfs:comment "STEP 10010 Add the contextFacility"^^xsd:string ;
627 sp:templates ([ sp:object 431 sp:templates ([ sp:object
628 - [ sp:varName "date"^^xsd:string 432 + [ sp:varName "contextFacility"^^xsd:string
629 ] ; 433 ] ;
630 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 434 + sp:predicate <http://www.reportinghub.no/ep/schema/geography#locatedWithin> ;
631 - sp:subject spin:_this 435 + sp:subject
436 + [ sp:varName "productionFacility"^^xsd:string
437 + ]
632 ]) ; 438 ]) ;
633 sp:where ([ sp:object 439 sp:where ([ sp:object
634 [ sp:varName "contextRef"^^xsd:string 440 [ sp:varName "contextRef"^^xsd:string
...@@ -641,63 +447,58 @@ ...@@ -641,63 +447,58 @@
641 [ sp:varName "contextRef"^^xsd:string 447 [ sp:varName "contextRef"^^xsd:string
642 ] 448 ]
643 ] [ sp:object 449 ] [ sp:object
644 - [ sp:varName "date"^^xsd:string 450 + [ sp:varName "contectFacilityRef"^^xsd:string
645 ] ; 451 ] ;
646 - sp:predicate <http://www.epim.no/schemas/mprml/1#date> ; 452 + sp:predicate <http://www.epim.no/schemas/mprml/1#contextFacilityRef> ;
647 sp:subject 453 sp:subject
648 [ sp:varName "contextRef"^^xsd:string 454 [ sp:varName "contextRef"^^xsd:string
649 ] 455 ]
650 - ] [ rdf:type sp:NotExists ; 456 + ] [ sp:object
651 - sp:elements ([ sp:object 457 + [ sp:varName "contextFacilityRef"^^xsd:string
652 - [ sp:varName "dateStart"^^xsd:string 458 + ] ;
653 - ] ; 459 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
654 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ; 460 + sp:subject
655 - sp:subject 461 + [ sp:varName "contextFacility"^^xsd:string
656 - [ sp:varName "contextRef"^^xsd:string 462 + ]
657 - ] 463 + ] [ sp:object spin:_this ;
658 - ]) 464 + sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
659 - ] [ rdf:type sp:NotExists ;
660 - sp:elements ([ sp:object
661 - [ sp:varName "dateEnd"^^xsd:string
662 - ] ;
663 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
664 - sp:subject
665 - [ sp:varName "contextRef"^^xsd:string
666 - ]
667 - ])
668 - ])
669 - ] ;
670 - spin:rule
671 - [ rdf:type sp:Construct ;
672 - rdfs:comment "STEP 10001m Create the ProductionReport - extract the name from context/installation"^^xsd:string ;
673 - sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
674 - sp:predicate rdf:type ;
675 sp:subject 465 sp:subject
676 [ sp:varName "productionReport"^^xsd:string 466 [ sp:varName "productionReport"^^xsd:string
677 ] 467 ]
678 - ] [ sp:object _:b4 ; 468 + ] [ sp:object
469 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
470 + ] ;
679 sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ; 471 sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ;
680 sp:subject 472 sp:subject
681 [ sp:varName "productionReport"^^xsd:string 473 [ sp:varName "productionReport"^^xsd:string
682 ] 474 ]
683 ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ; 475 ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
684 sp:predicate rdf:type ; 476 sp:predicate rdf:type ;
685 - sp:subject _:b4 477 + sp:subject
478 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
479 + ]
686 ] [ sp:object 480 ] [ sp:object
687 - [ sp:varName "installation"^^xsd:string 481 + [ sp:varName "productionFacility"^^xsd:string
688 ] ; 482 ] ;
689 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ; 483 sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
690 - sp:subject _:b4 484 + sp:subject
485 + [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
486 + ]
487 + ])
488 + ] ;
489 + spin:rule
490 + [ rdf:type sp:Construct ;
491 + rdfs:comment "STEP 10001m Create the ProductionReport - extract the name from productVolume/installation where the installation is a field"^^xsd:string ;
492 + sp:templates ([ sp:object <http://www.reportinghub.no/ep/schema/report#ProductionReport> ;
493 + sp:predicate rdf:type ;
494 + sp:subject
495 + [ sp:varName "productionReport"^^xsd:string
496 + ]
691 ] [ sp:object spin:_this ; 497 ] [ sp:object spin:_this ;
692 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ; 498 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
693 sp:subject 499 sp:subject
694 [ sp:varName "productionReport"^^xsd:string 500 [ sp:varName "productionReport"^^xsd:string
695 ] 501 ]
696 - ] [ sp:object
697 - [ sp:varName "contextRef"^^xsd:string
698 - ] ;
699 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
700 - sp:subject _:b4
701 ]) ; 502 ]) ;
702 sp:where ([ sp:object 503 sp:where ([ sp:object
703 [ sp:varName "intervalIdentifier"^^xsd:string 504 [ sp:varName "intervalIdentifier"^^xsd:string
...@@ -705,21 +506,21 @@ ...@@ -705,21 +506,21 @@
705 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ; 506 sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
706 sp:subject spin:_this 507 sp:subject spin:_this
707 ] [ sp:object 508 ] [ sp:object
708 - [ sp:varName "contextRef"^^xsd:string 509 + [ sp:varName "productVolumeRef"^^xsd:string
709 ] ; 510 ] ;
710 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ; 511 + sp:predicate <http://www.epim.no/schemas/mprml/1#objectRef> ;
711 sp:subject spin:_this 512 sp:subject spin:_this
712 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ; 513 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_productVolume> ;
713 sp:predicate rdf:type ; 514 sp:predicate rdf:type ;
714 sp:subject 515 sp:subject
715 - [ sp:varName "contextRef"^^xsd:string 516 + [ sp:varName "productVolumeRef"^^xsd:string
716 ] 517 ]
717 ] [ sp:object 518 ] [ sp:object
718 [ sp:varName "installationRef"^^xsd:string 519 [ sp:varName "installationRef"^^xsd:string
719 ] ; 520 ] ;
720 sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ; 521 sp:predicate <http://www.epim.no/schemas/mprml/1#installationRef> ;
721 sp:subject 522 sp:subject
722 - [ sp:varName "contextRef"^^xsd:string 523 + [ sp:varName "productVolumeRef"^^xsd:string
723 ] 524 ]
724 ] [ sp:object 525 ] [ sp:object
725 [ sp:varName "installationRef"^^xsd:string 526 [ sp:varName "installationRef"^^xsd:string
...@@ -728,6 +529,11 @@ ...@@ -728,6 +529,11 @@
728 sp:subject 529 sp:subject
729 [ sp:varName "installation"^^xsd:string 530 [ sp:varName "installation"^^xsd:string
730 ] 531 ]
532 + ] [ sp:object <http://www.epim.no/schemas/mprml/1#RF_field> ;
533 + sp:predicate <http://www.epim.no/schemas/mprml/1#kindRef> ;
534 + sp:subject
535 + [ sp:varName "installationRef"^^xsd:string
536 + ]
731 ] [ rdf:type sp:Bind ; 537 ] [ rdf:type sp:Bind ;
732 sp:expression 538 sp:expression
733 [ rdf:type spl:object ; 539 [ rdf:type spl:object ;
...@@ -750,112 +556,6 @@ ...@@ -750,112 +556,6 @@
750 [ sp:varName "productionReport"^^xsd:string 556 [ sp:varName "productionReport"^^xsd:string
751 ] 557 ]
752 ]) 558 ])
753 - ] ;
754 - spin:rule
755 - [ rdf:type sp:Construct ;
756 - rdfs:comment "STEP 10001d Create the interval identifier - dateEnd from context"^^xsd:string ;
757 - sp:templates ([ sp:object
758 - [ sp:varName "dateEnd"^^xsd:string
759 - ] ;
760 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#intervalIdentifier> ;
761 - sp:subject spin:_this
762 - ]) ;
763 - sp:where ([ sp:object
764 - [ sp:varName "contextRef"^^xsd:string
765 - ] ;
766 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
767 - sp:subject spin:_this
768 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
769 - sp:predicate rdf:type ;
770 - sp:subject
771 - [ sp:varName "contextRef"^^xsd:string
772 - ]
773 - ] [ sp:object
774 - [ sp:varName "dateEnd"^^xsd:string
775 - ] ;
776 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateEnd> ;
777 - sp:subject
778 - [ sp:varName "contextRef"^^xsd:string
779 - ]
780 - ] [ rdf:type sp:NotExists ;
781 - sp:elements ([ sp:object
782 - [ sp:varName "date"^^xsd:string
783 - ] ;
784 - sp:predicate <http://www.epim.no/schemas/mprml/1#date> ;
785 - sp:subject
786 - [ sp:varName "contextRef"^^xsd:string
787 - ]
788 - ])
789 - ] [ rdf:type sp:NotExists ;
790 - sp:elements ([ sp:object
791 - [ sp:varName "dateStart"^^xsd:string
792 - ] ;
793 - sp:predicate <http://www.epim.no/schemas/mprml/1#dateStart> ;
794 - sp:subject
795 - [ sp:varName "contextRef"^^xsd:string
796 - ]
797 - ])
798 - ])
799 - ] ;
800 - spin:rule
801 - [ rdf:type sp:Construct ;
802 - rdfs:comment "STEP 10020 Add the operator"^^xsd:string ;
803 - sp:templates ([ sp:object _:b5 ;
804 - sp:predicate <http://www.reportinghub.no/ep/schema/facility#facilityOperator> ;
805 - sp:subject
806 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
807 - ]
808 - ] [ sp:object <http://www.reportinghub.no/ep/schema/organization#Organization> ;
809 - sp:predicate rdf:type ;
810 - sp:subject _:b5
811 - ] [ sp:object
812 - [ sp:varName "operator"^^xsd:string
813 - ] ;
814 - sp:predicate <http://www.reportinghub.no/ep/schema/core#temporalPartOf> ;
815 - sp:subject _:b5
816 - ]) ;
817 - sp:where ([ sp:object
818 - [ sp:varName "contextRef"^^xsd:string
819 - ] ;
820 - sp:predicate <http://www.epim.no/schemas/mprml/1#contextRef> ;
821 - sp:subject spin:_this
822 - ] [ sp:object <http://www.epim.no/schemas/mprml/1#Obj_report> ;
823 - sp:predicate rdf:type ;
824 - sp:subject
825 - [ sp:varName "contextRef"^^xsd:string
826 - ]
827 - ] [ sp:object
828 - [ sp:varName "operatorRef"^^xsd:string
829 - ] ;
830 - sp:predicate <http://www.epim.no/schemas/mprml/1#operatorRef> ;
831 - sp:subject
832 - [ sp:varName "contextRef"^^xsd:string
833 - ]
834 - ] [ sp:object
835 - [ sp:varName "operatorRef"^^xsd:string
836 - ] ;
837 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
838 - sp:subject
839 - [ sp:varName "operator"^^xsd:string
840 - ]
841 - ] [ sp:object spin:_this ;
842 - sp:predicate <http://www.reportinghub.no/ep/transform/transform-helper-schema#derivedFrom> ;
843 - sp:subject
844 - [ sp:varName "productionReport"^^xsd:string
845 - ]
846 - ] [ sp:object
847 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
848 - ] ;
849 - sp:predicate <http://www.reportinghub.no/ep/schema/report#reportOn> ;
850 - sp:subject
851 - [ sp:varName "productionReport"^^xsd:string
852 - ]
853 - ] [ sp:object <http://www.reportinghub.no/ep/schema/facility#TemporalPartOfAProductionFacility> ;
854 - sp:predicate rdf:type ;
855 - sp:subject
856 - [ sp:varName "temporalPartOfAProductionFacility"^^xsd:string
857 - ]
858 - ])
859 ] . 559 ] .
860 560
861 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-productionReport-v1.0> 561 <http://www.reportinghub.no/ep/transform/TRANSFORM_mpr-productionReport-v1.0>
......