Index: trunk/extensions/Wikidata/OmegaWiki/SpecialTransaction.php |
— | — | @@ -131,8 +131,6 @@ |
132 | 132 | |
133 | 133 | $o=OmegaWikiAttributes::getInstance(); |
134 | 134 | |
135 | | - $o=OmegaWikiAttributes::getInstance(); |
136 | | - |
137 | 135 | $o->operation = new Attribute('operation', 'Operation', 'text'); |
138 | 136 | $o->isLatest = new Attribute('is-latest', 'Is latest', 'boolean'); |
139 | 137 | |
— | — | @@ -149,57 +147,46 @@ |
150 | 148 | $o->translatedContentHistory = new Attribute('translated-content-history', 'History', $o->translatedContentHistoryStructure); |
151 | 149 | $o->translatedContentId = new Attribute('translated-content-id', 'Translated content ID', 'object-id'); |
152 | 150 | |
153 | | - |
154 | | - $o=OmegaWikiAttributes::getInstance(); |
155 | | - |
156 | | - $o->rollBackTranslatedContentStructure = new Structure($isLatestAttribute, $operationAttribute, $translatedContentHistoryAttribute); |
| 151 | + $o->rollBackTranslatedContentStructure = new Structure($o->isLatest, $o->operation, $o->translatedContentHistory); |
157 | 152 | $o->rollBackTranslatedContent = new Attribute('roll-back', 'Roll back', $o->rollBackTranslatedContentStructure); |
158 | 153 | |
159 | 154 | |
160 | | - $o=OmegaWikiAttributes::getInstance(); |
161 | | - |
162 | 155 | $o->updatedDefinitionStructure = new Structure( |
163 | | - $rollBackTranslatedContentAttribute, |
164 | | - $definedMeaningIdAttribute, |
165 | | - $definedMeaningReferenceAttribute, |
166 | | - $translatedContentIdAttribute, |
| 156 | + $o->rollBackTranslatedContent, |
| 157 | + $o->definedMeaningId, |
| 158 | + $o->definedMeaningReference, |
| 159 | + $o->translatedContentId, |
167 | 160 | $o->language, |
168 | 161 | $o->text, |
169 | | - $operationAttribute, |
170 | | - $isLatestAttribute |
| 162 | + $o->operation, |
| 163 | + $o->isLatest |
171 | 164 | ); |
172 | 165 | |
173 | 166 | $o->updatedDefinition = new Attribute('updated-definition', 'Definition', $o->updatedDefinitionStructure); |
174 | 167 | |
175 | | - |
176 | | - $o=OmegaWikiAttributes::getInstance(); |
177 | | - |
178 | 168 | $o->updatedSyntransesStructure = new Structure( |
179 | 169 | $o->syntransId, |
180 | | - $definedMeaningIdAttribute, |
181 | | - $definedMeaningReferenceAttribute, |
| 170 | + $o->definedMeaningId, |
| 171 | + $o->definedMeaningReference, |
182 | 172 | $o->expressionId, |
183 | 173 | $o->expression, |
184 | 174 | $o->identicalMeaning, |
185 | | - $operationAttribute |
| 175 | + $o->operation |
186 | 176 | ); |
187 | 177 | |
188 | 178 | $o->updatedSyntranses = new Attribute('updated-syntranses', 'Synonyms and translations', $o->updatedSyntransesStructure); |
189 | 179 | |
| 180 | + $o->firstMeaning = new Attribute('first-meaning', "First defined meaning", $o->definedMeaningReferenceStructure); |
| 181 | + $o->secondMeaning = new Attribute('second-meaning', "Second defined meaning", $o->definedMeaningReferenceStructure); |
190 | 182 | |
191 | | - $o=OmegaWikiAttributes::getInstance(); |
192 | | - |
193 | | - $o->firstMeaning = new Attribute('first-meaning', "First defined meaning", $definedMeaningReferenceStructure); |
194 | | - $o->secondMeaning = new Attribute('second-meaning', "Second defined meaning", $definedMeaningReferenceStructure); |
195 | | - |
196 | 183 | $o->updatedRelationsStructure = new Structure( |
197 | | - $rollBackAttribute, |
| 184 | + $o->rollBack, |
198 | 185 | $o->relationId, |
199 | 186 | $o->firstMeaning, |
200 | 187 | $o->relationType, |
201 | 188 | $o->secondMeaning, |
202 | | - $operationAttribute, |
203 | | - $isLatestAttribute |
| 189 | + $o->operation, |
| 190 | + $o->isLatest |
204 | 191 | ); |
205 | 192 | |
206 | 193 | $o->updatedRelations = new Attribute('updated-relations', 'Relations', $o->updatedRelationsStructure); |
— | — | @@ -207,90 +194,80 @@ |
208 | 195 | |
209 | 196 | $o=OmegaWikiAttributes::getInstance(); |
210 | 197 | |
211 | | - $o->classMember = new Attribute('class-member', 'Class member', $definedMeaningReferenceStructure); |
| 198 | + $o->classMember = new Attribute('class-member', 'Class member', $o->definedMeaningReferenceStructure); |
212 | 199 | |
213 | 200 | $o->updatedClassMembershipStructure = new Structure( |
214 | | - $rollBackAttribute, |
| 201 | + $o->rollBack, |
215 | 202 | $o->classMembershipId, |
216 | 203 | $o->class, |
217 | 204 | $o->classMember, |
218 | | - $operationAttribute, |
219 | | - $isLatestAttribute |
| 205 | + $o->operation, |
| 206 | + $o->isLatest |
220 | 207 | ); |
221 | 208 | |
222 | 209 | $o->updatedClassMembership = new Attribute('updated-class-membership', 'Class membership', $o->updatedClassMembershipStructure); |
223 | 210 | |
224 | 211 | |
225 | | - $o=OmegaWikiAttributes::getInstance(); |
226 | 212 | |
227 | | - $o->collectionMember = new Attribute('collection-member', 'Collection member', $definedMeaningReferenceStructure); |
| 213 | + $o->collectionMember = new Attribute('collection-member', 'Collection member', $o->definedMeaningReferenceStructure); |
228 | 214 | $o->collectionMemberId = new Attribute('collection-member-id', 'Collection member identifier', 'defined-meaning-id'); |
229 | 215 | |
230 | 216 | $o->updatedCollectionMembershipStructure = new Structure( |
231 | | - $rollBackAttribute, |
| 217 | + $o->rollBack, |
232 | 218 | $o->collectionId, |
233 | 219 | $o->collectionMeaning, |
234 | 220 | $o->collectionMemberId, |
235 | 221 | $o->collectionMember, |
236 | 222 | $o->sourceIdentifier, |
237 | | - $operationAttribute |
| 223 | + $o->operation |
238 | 224 | ); |
239 | 225 | |
240 | 226 | $o->updatedCollectionMembership = new Attribute('updated-collection-membership', 'Collection membership', $o->updatedCollectionMembershipStructure); |
241 | 227 | |
242 | 228 | |
243 | | - $o=OmegaWikiAttributes::getInstance(); |
244 | 229 | |
245 | 230 | $o->objectId = new Attribute('object-id', 'Object', 'object-id'); |
246 | 231 | $o->valueId = new Attribute('value-id', 'Value identifier', 'object-id'); |
247 | | - $o->attribute = new Attribute('attribute', 'Attribute', $definedMeaningReferenceStructure); |
| 232 | + $o->attribute = new Attribute('attribute', 'Attribute', $o->definedMeaningReferenceStructure); |
248 | 233 | |
249 | 234 | |
250 | | - $o=OmegaWikiAttributes::getInstance(); |
251 | 235 | |
252 | 236 | $o->updatedLinkStructure = new Structure( |
253 | | - $rollBackAttribute, |
254 | | - $valueIdAttribute, |
255 | | - $objectIdAttribute, |
256 | | - $attributeAttribute, |
| 237 | + $o->rollBack, |
| 238 | + $o->valueId, |
| 239 | + $o->objectId, |
| 240 | + $o->attribute, |
257 | 241 | $o->link, |
258 | | - $operationAttribute, |
259 | | - $isLatestAttribute |
| 242 | + $o->operation, |
| 243 | + $o->isLatest |
260 | 244 | ); |
261 | 245 | |
262 | 246 | $o->updatedLink = new Attribute('updated-link', 'Link properties', $o->updatedLinkStructure); |
263 | 247 | |
264 | 248 | |
265 | | - $o=OmegaWikiAttributes::getInstance(); |
266 | | - |
267 | | - $o=OmegaWikiAttributes::getInstance(); |
268 | | - |
269 | 249 | $o->updatedTextStructure = new Structure( |
270 | | - $rollBackAttribute, |
271 | | - $valueIdAttribute, |
272 | | - $objectIdAttribute, |
273 | | - $attributeAttribute, |
| 250 | + $o->rollBack, |
| 251 | + $o->valueId, |
| 252 | + $o->objectId, |
| 253 | + $o->attribute, |
274 | 254 | $o->text, |
275 | | - $operationAttribute, |
276 | | - $isLatestAttribute |
| 255 | + $o->operation, |
| 256 | + $o->isLatest |
277 | 257 | ); |
278 | 258 | |
279 | 259 | $o->updatedText = new Attribute('updated-text', 'Unstructured text properties', $o->updatedTextStructure); |
280 | 260 | |
281 | | - |
282 | | - $o=OmegaWikiAttributes::getInstance(); |
283 | | - |
284 | 261 | $o->translatedTextText = new Attribute('translated-text-property-text', 'Text', $o->translatedTextStructure); |
285 | 262 | |
286 | 263 | $o->updatedTranslatedTextPropertyStructure = new Structure( |
287 | | - $rollBackAttribute, |
288 | | - $valueIdAttribute, |
289 | | - $objectIdAttribute, |
290 | | - $attributeAttribute, |
291 | | - $translatedContentIdAttribute, |
| 264 | + $o->rollBack, |
| 265 | + $o->valueId, |
| 266 | + $o->objectId, |
| 267 | + $o->attribute, |
| 268 | + $o->translatedContentId, |
292 | 269 | $o->translatedTextText, |
293 | | - $operationAttribute, |
294 | | - $isLatestAttribute |
| 270 | + $o->operation, |
| 271 | + $o->isLatest |
295 | 272 | ); |
296 | 273 | |
297 | 274 | $o->updatedTranslatedTextProperty = new Attribute('updated-translated-text-property', 'Text properties', $o->updatedTranslatedTextPropertyStructure); |
— | — | @@ -299,87 +276,78 @@ |
300 | 277 | $o=OmegaWikiAttributes::getInstance(); |
301 | 278 | |
302 | 279 | $o->updatedTranslatedTextStructure = new Structure( |
303 | | - $rollBackTranslatedContentAttribute, |
304 | | - $valueIdAttribute, |
305 | | - $objectIdAttribute, |
306 | | - $attributeAttribute, |
307 | | - $translatedContentIdAttribute, |
| 280 | + $o->rollBackTranslatedContent, |
| 281 | + $o->valueId, |
| 282 | + $o->objectId, |
| 283 | + $o->attribute, |
| 284 | + $o->translatedContentId, |
308 | 285 | $o->language, |
309 | 286 | $o->text, |
310 | | - $operationAttribute, |
311 | | - $isLatestAttribute |
| 287 | + $o->operation, |
| 288 | + $o->isLatest |
312 | 289 | ); |
313 | 290 | |
314 | 291 | $o->updatedTranslatedText = new Attribute('updated-translated-text', 'Texts', $o->updatedTranslatedTextStructure); |
315 | 292 | |
316 | 293 | |
317 | | - $o=OmegaWikiAttributes::getInstance(); |
318 | | - |
319 | 294 | $o->classId = new Attribute('class-attribute-id', 'Class attribute id', 'object-id'); |
320 | | - $o->level = new Attribute('level', 'Level', $definedMeaningReferenceStructure); |
| 295 | + $o->level = new Attribute('level', 'Level', $o->definedMeaningReferenceStructure); |
321 | 296 | $o->type = new Attribute('type', 'Type', 'text'); |
322 | 297 | |
323 | 298 | $o->updatedClassAttributesStructure = new Structure( |
324 | | - $rollBackAttribute, |
| 299 | + $o->rollBack, |
325 | 300 | $o->classId, |
326 | 301 | $o->class, |
327 | 302 | $o->level, |
328 | 303 | $o->type, |
329 | | - $attributeAttribute, |
330 | | - $operationAttribute, |
331 | | - $isLatestAttribute |
| 304 | + $o->attribute, |
| 305 | + $o->operation, |
| 306 | + $o->isLatest |
332 | 307 | ); |
333 | 308 | |
334 | 309 | $o->updatedClassAttributes = new Attribute('updated-class-attributes', 'Class attributes', $o->updatedClassAttributesStructure); |
335 | 310 | |
| 311 | + $o->alternativeDefinitionText = new Attribute('alternative-definition-text', 'Definition', $o->translatedTextStructure); |
| 312 | + $o->source = new Attribute('source', 'Source', $o->definedMeaningReferenceStructure); |
336 | 313 | |
337 | | - $o=OmegaWikiAttributes::getInstance(); |
338 | | - |
339 | | - $o->alternativeDefinitionText = new Attribute('alternative-definition-text', 'Definition', $translatedTextStructure); |
340 | | - $o->source = new Attribute('source', 'Source', $definedMeaningReferenceStructure); |
341 | | - |
342 | 314 | $o->updatedAlternativeDefinitionsStructure = new Structure( |
343 | | - $rollBackAttribute, |
344 | | - $definedMeaningIdAttribute, |
345 | | - $translatedContentIdAttribute, |
| 315 | + $o->rollBack, |
| 316 | + $o->definedMeaningId, |
| 317 | + $o->translatedContentId, |
346 | 318 | $o->alternativeDefinitionText, |
347 | | - $definedMeaningReferenceAttribute, |
| 319 | + $o->definedMeaningReference, |
348 | 320 | $o->source, |
349 | | - $operationAttribute, |
350 | | - $isLatestAttribute |
| 321 | + $o->operation, |
| 322 | + $o->isLatest |
351 | 323 | ); |
352 | 324 | |
353 | 325 | $o->updatedAlternativeDefinitions = new Attribute('updated-alternative-definitions', 'Alternative definitions', $o->updatedAlternativeDefinitionsStructure); |
354 | 326 | |
355 | | - |
356 | | - $o=OmegaWikiAttributes::getInstance(); |
357 | 327 | |
358 | 328 | $o->updatedAlternativeDefinitionTextStructure = new Structure( |
359 | | - $rollBackTranslatedContentAttribute, |
360 | | - $definedMeaningIdAttribute, |
361 | | - $definedMeaningReferenceAttribute, |
362 | | - $translatedContentIdAttribute, |
363 | | - $sourceAttribute, |
| 329 | + $o->rollBackTranslatedContent, |
| 330 | + $o->definedMeaningId, |
| 331 | + $o->definedMeaningReference, |
| 332 | + $o->translatedContentId, |
| 333 | + $o->source, |
364 | 334 | $o->language, |
365 | 335 | $o->text, |
366 | | - $operationAttribute, |
367 | | - $isLatestAttribute |
| 336 | + $o->operation, |
| 337 | + $o->isLatest |
368 | 338 | ); |
369 | 339 | |
370 | 340 | $o->updatedAlternativeDefinitionText = new Attribute('updated-alternative-definition-text', 'Alternative definition text', $o->updatedAlternativeDefinitionTextStructure); |
371 | 341 | |
372 | 342 | |
373 | | - $o=OmegaWikiAttributes::getInstance(); |
374 | | - |
375 | 343 | $updatesInTransactionStructure = new Structure( |
376 | | - $updatedDefinitionAttribute, |
377 | | - $updatedSyntransesAttribute, |
378 | | - $updatedRelationsAttribute, |
379 | | - $updatedClassMembershipAttribute, |
380 | | - $updatedLinkAttribute, |
381 | | - $updatedTextAttribute, |
382 | | - $updatedTranslatedTextAttribute, |
383 | | - $updatedAlternativeDefinitionsAttribute |
| 344 | + $o->updatedDefinition, |
| 345 | + $o->updatedSyntranses, |
| 346 | + $o->updatedRelations, |
| 347 | + $o->updatedClassMembership, |
| 348 | + $o->updatedLink, |
| 349 | + $o->updatedText, |
| 350 | + $o->updatedTranslatedText, |
| 351 | + $o->updatedAlternativeDefinitions |
384 | 352 | ); |
385 | 353 | |
386 | 354 | $o->updatesInTransaction = new Attribute('updates-in-transaction', 'Updates in transaction', $updatesInTransactionStructure); |