constructor-expression-result-feature-redefinition
Available in: KerML, SysML
This checks that constructors arguments are bound to the instantiated type features only, and only once.
Specification
Each
owned_featureof theresultof aConstructionExpressionmust redefine exactly onepublicfeatureof theinstantiated_typeof theConstructorExpression.
Example
attribute def A;
attribute a = new A(0,2); // error: Constructor expression argument must redefine an input or an undirected feature
Remove extraneous arguments:
attribute def A;
attribute a = new A(0); // ok