diff options
author | ArenBabikian <aren.babikian@mail.mcgill.ca> | 2020-05-10 20:56:55 -0400 |
---|---|---|
committer | ArenBabikian <aren.babikian@mail.mcgill.ca> | 2020-05-10 20:56:55 -0400 |
commit | fb99d0d2a8ddcd7bad3b1f59152328e76ae8edb6 (patch) | |
tree | 4ee9262ebb91eb6bf8a84af0f771d6c4366c7b0d /Tests/MODELS2020-CaseStudies/case.study.pledge.run/src/queries/case_study_A.vql | |
parent | Satelite case study update for Models-Attribute paper (diff) | |
download | VIATRA-Generator-fb99d0d2a8ddcd7bad3b1f59152328e76ae8edb6.tar.gz VIATRA-Generator-fb99d0d2a8ddcd7bad3b1f59152328e76ae8edb6.tar.zst VIATRA-Generator-fb99d0d2a8ddcd7bad3b1f59152328e76ae8edb6.zip |
Fix PLEDGE Case Study File
Diffstat (limited to 'Tests/MODELS2020-CaseStudies/case.study.pledge.run/src/queries/case_study_A.vql')
-rw-r--r-- | Tests/MODELS2020-CaseStudies/case.study.pledge.run/src/queries/case_study_A.vql | 33 |
1 files changed, 19 insertions, 14 deletions
diff --git a/Tests/MODELS2020-CaseStudies/case.study.pledge.run/src/queries/case_study_A.vql b/Tests/MODELS2020-CaseStudies/case.study.pledge.run/src/queries/case_study_A.vql index f736ec58..01cdf372 100644 --- a/Tests/MODELS2020-CaseStudies/case.study.pledge.run/src/queries/case_study_A.vql +++ b/Tests/MODELS2020-CaseStudies/case.study.pledge.run/src/queries/case_study_A.vql | |||
@@ -285,29 +285,34 @@ pattern inv47(lur : Legal_Union_Record) { | |||
285 | Legal_Union_Record.start_year(lur, startY); | 285 | Legal_Union_Record.start_year(lur, startY); |
286 | neg find x_inv47(lur); | 286 | neg find x_inv47(lur); |
287 | check(startY >= endY); | 287 | check(startY >= endY); |
288 | } or { | ||
289 | Legal_Union_Record.end_year(lur, endY); | ||
290 | Legal_Union_Record.start_year(lur, startY); | ||
291 | check(endY!= -1); | ||
292 | check(startY >= endY); | ||
288 | } | 293 | } |
289 | pattern x_inv47(lur : Legal_Union_Record) { | 294 | pattern x_inv47(lur : Legal_Union_Record) { |
290 | Legal_Union_Record.separation_cause(lur, ::NONE); | 295 | Legal_Union_Record.separation_cause(lur, ::NONE); |
291 | Legal_Union_Record.end_year(lur, -1); | ||
292 | } | 296 | } |
293 | 297 | ||
294 | //inv48-attributes-handled by multiplicity | 298 | //inv48-attributes-handled by multiplicity |
295 | @Constraint(message = "inv48", severity = "error", key = {p}) | 299 | @Constraint(message = "inv48", severity = "error", key = {p}) |
296 | pattern inv48(p : Physical_Person) { | 300 | pattern inv48(p : Physical_Person) { |
297 | neg find x_inv48_notDis(p); | 301 | Physical_Person.disability_percentage(p, disPer); |
298 | neg find x_inv48_Dis(p); | 302 | check(disPer > 1.0); |
299 | } | 303 | } or { |
300 | pattern x_inv48_notDis(p : Physical_Person) { | 304 | Physical_Person.disability_percentage(p, disPer); |
301 | Physical_Person.disability_type(p, ::NONE); | 305 | check(disPer < 0.0); |
302 | Physical_Person.disability_percentage(p, 0.0); | 306 | } or { |
303 | } | 307 | Physical_Person.disability_type(p, ::NONE); |
304 | pattern x_inv48_Dis(p : Physical_Person) { | 308 | Physical_Person.disability_percentage(p, disPer); |
305 | neg find x_inv48_3(p); | 309 | check(disPer != 0.0); |
306 | Physical_Person.disability_percentage(p, disPer); | 310 | } or { |
307 | check(disPer > 0.0); | 311 | neg find x_inv48(p); |
308 | check(disPer <= 1.0); | 312 | Physical_Person.disability_percentage(p, disPer); |
313 | check(disPer == 0.0); | ||
309 | } | 314 | } |
310 | pattern x_inv48_3(p : Physical_Person) { | 315 | pattern x_inv48(p : Physical_Person) { |
311 | Physical_Person.disability_type(p, ::NONE); | 316 | Physical_Person.disability_type(p, ::NONE); |
312 | } | 317 | } |
313 | 318 | ||