Search in sources :

Example 1 with ConstraintsContext

use of org.finos.legend.pure.m3.serialization.grammar.m3parser.antlr.M3Parser.ConstraintsContext in project legend-pure by finos.

the class AntlrContextToM3CoreInstance method constraints.

private MutableList<Constraint> constraints(CoreInstance owner, ConstraintsContext ctx, ImportGroup importId, LambdaContext lambdaContext, boolean addLines) {
    MutableList<Constraint> constraints = Lists.mutable.empty();
    if (ctx != null) {
        int i = 0;
        for (ConstraintContext cCtx : ctx.constraint()) {
            constraints.add(this.constraint(owner, cCtx, i, importId, lambdaContext, addLines, false));
            i++;
        }
    }
    return constraints;
}
Also used : Constraint(org.finos.legend.pure.m3.coreinstance.meta.pure.metamodel.constraint.Constraint) ConstraintContext(org.finos.legend.pure.m3.serialization.grammar.m3parser.antlr.M3Parser.ConstraintContext) Constraint(org.finos.legend.pure.m3.coreinstance.meta.pure.metamodel.constraint.Constraint)

Aggregations

Constraint (org.finos.legend.pure.m3.coreinstance.meta.pure.metamodel.constraint.Constraint)1 ConstraintContext (org.finos.legend.pure.m3.serialization.grammar.m3parser.antlr.M3Parser.ConstraintContext)1