Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mandatory Constraint fails with links to multiple objects (ILI2.4) #404

Open
Tracked by #418
beistehen opened this issue Feb 13, 2024 · 1 comment
Open
Tracked by #418

Comments

@beistehen
Copy link
Contributor

(Testmodell mit weiteren Kommentaren und Daten im Anhang)

Gegeben sei dieses Testmodell:

MODEL model_a (de) AT "mailto:stehen@localhost" VERSION "2024-02-13" =

  TOPIC topic_a =

    CLASS ca =
    END ca;

    CLASS cb = 
      attr1_cb : (rot, gruen, blau);
    END cb;

    ASSOCIATION ab =
      aRef -- {0 .. 1} ca;
      bRef -- {0 .. *} cb;
    END ab;

    CONSTRAINTS OF ca =

      !!@ name = rot
      MANDATORY CONSTRAINT NOT(bRef->attr1_cb == #rot);

      !!@ name = gruen
      MANDATORY CONSTRAINT NOT(bRef->attr1_cb == #gruen);

      !!@ name = blau
      MANDATORY CONSTRAINT NOT(bRef->attr1_cb == #blau);

    END;

  END topic_a;

END model_a.

In den Transferdaten hat 1 Objekt ca zwei Links zu je einem Objekt cb mit je unterschiedlichem Attributwert für attr1_cb. Mittels der definierten Constraints wird jedoch nur eines dieser beiden Objekte cb detektiert. Meine Erwartung wäre, dass die Constraints auf beide verlinkten Objekte angewandt würden.

constraint_tests.zip


Umgebung:

Info: ilivalidator-1.14.1-24c5f1a82700e85e9fe4dd7a101a207f42ae17ae
Info: ili2c-5.4.1-b49d62c05c4a212d9a0aa81797efd5185ed288af
Info: iox-ili-1.22.1-386e912e5e6476b0f04a3cc650c3d9a4b762718e
Info: java.version 1.8.0_282
@sjib
Copy link

sjib commented Aug 7, 2024

@beistehen Irgendwelche Fortschritte hier?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants