{ * File: W31.sml.txt * Author: Michael Schrefl, Bernd Neumayr, Manfred Jeusfeld * Created: 15-Nov-2013/M.Jeusfeld (15-Nov-2013/M.Jeusfeld) * ------------------------------------------------------ * Example on the benefit of using R/D attributes. * We want to model that products have prices in any * currency except for CrudeOil, which must have prices in Dollar * W31 fails because it violates d3b. * } Price in ALABEL end Currency in OBJECT end ProductType in OBJECT with linkDR m1: Currency end ProductType!m1 with sourcelevel s: 2 targetlevel t: 2 label l: Price end CrudeOil in OBJECT with IN c: ProductType linkDR m1: Dollar end CrudeOil!m1 with sourcelevel s: 1 targetlevel t: 1 label l: Price end JetFuel in OBJECT with IN c: ProductType end Dollar in OBJECT with IN c: Currency end Euro in OBJECT with IN c: Currency end Brent in OBJECT with IN c: CrudeOil linkDR m1: "20Dollar" end Brent!m1 with sourcelevel s: 0 targetlevel t: 0 label l: Price end JetB in OBJECT with IN c: JetFuel linkDR m1: "20Dollar" end JetB!m1 with sourcelevel s: 0 targetlevel t: 0 label l: Price end "20Dollar" in OBJECT with IN c: Dollar end "17Euro" in OBJECT with IN c: Euro end