Package org.drools.workbench.models.datamodel.rule

Examples of org.drools.workbench.models.datamodel.rule.RuleModelVisitor.visit()


                //Get interpolation variables used by the Action
                Map<InterpolationVariable, Integer> ivs = new HashMap<InterpolationVariable, Integer>();
                RuleModelVisitor rmv = new RuleModelVisitor( action,
                                                             ivs );
                rmv.visit( action );

                if ( ivs.size() > 0 ) {

                    //Ensure every key has a value and substitute keys for values
                    for ( InterpolationVariable variable : ivs.keySet() ) {
View Full Code Here


        RuleModel rm = new RuleModel();
        for ( IAction action : column.getDefinition() ) {
            rm.addRhsItem( action );
        }
        RuleModelVisitor rmv = new RuleModelVisitor( ivs );
        rmv.visit( rm );
        return ivs.size() > 0;
    }

    private void addAction( IAction action,
                            List<LabelledAction> actions ) {
View Full Code Here

                //Get interpolation variables used by the Pattern
                Map<InterpolationVariable, Integer> ivs = new HashMap<InterpolationVariable, Integer>();
                RuleModelVisitor rmv = new RuleModelVisitor( pattern,
                                                             ivs );
                rmv.visit( pattern );

                if ( ivs.size() > 0 ) {

                    //Ensure every key has a value and substitute keys for values
                    for ( InterpolationVariable variable : ivs.keySet() ) {
View Full Code Here

        RuleModel rm = new RuleModel();
        for ( IPattern pattern : column.getDefinition() ) {
            rm.addLhsItem( pattern );
        }
        RuleModelVisitor rmv = new RuleModelVisitor( ivs );
        rmv.visit( rm );
        return ivs.size() > 0;
    }

    private void doCondition( List<BaseColumn> allColumns,
                              Pattern52 pattern,
View Full Code Here

    //Extract Template Keys from RuleModel
    private boolean getDefinedVariables( RuleModel ruleModel ) {
        Map<InterpolationVariable, Integer> ivs = new HashMap<InterpolationVariable, Integer>();
        RuleModelVisitor rmv = new RuleModelVisitor( ivs );
        rmv.visit( ruleModel );

        //Update column and UI
        editingCol.setChildColumns( convertInterpolationVariables( ivs ) );

        return ivs.size() > 0;
View Full Code Here

    //Extract Template Keys from RuleModel
    private boolean getDefinedVariables( RuleModel ruleModel ) {
        Map<InterpolationVariable, Integer> ivs = new HashMap<InterpolationVariable, Integer>();
        RuleModelVisitor rmv = new RuleModelVisitor( ivs );
        rmv.visit( ruleModel );

        //Update column and UI
        editingCol.setChildColumns( convertInterpolationVariables( ivs ) );

        return ivs.size() > 0;
View Full Code Here

                //Get interpolation variables used by the Action
                Map<InterpolationVariable, Integer> ivs = new HashMap<InterpolationVariable, Integer>();
                RuleModelVisitor rmv = new RuleModelVisitor( action,
                                                             ivs );
                rmv.visit( action );

                if ( addAction ) {
                    addAction( action,
                               actions );
                }
View Full Code Here

        RuleModel rm = new RuleModel();
        for ( IAction action : column.getDefinition() ) {
            rm.addRhsItem( action );
        }
        RuleModelVisitor rmv = new RuleModelVisitor( ivs );
        rmv.visit( rm );
        return ivs.size() > 0;
    }

    private void addAction( IAction action,
                            List<LabelledAction> actions ) {
View Full Code Here

                //Get interpolation variables used by the Pattern
                Map<InterpolationVariable, Integer> ivs = new HashMap<InterpolationVariable, Integer>();
                RuleModelVisitor rmv = new RuleModelVisitor( pattern,
                                                             ivs );
                rmv.visit( pattern );

                if ( addPattern ) {
                    patterns.add( pattern );
                }
View Full Code Here

        RuleModel rm = new RuleModel();
        for ( IPattern pattern : column.getDefinition() ) {
            rm.addLhsItem( pattern );
        }
        RuleModelVisitor rmv = new RuleModelVisitor( ivs );
        rmv.visit( rm );
        return ivs.size() > 0;
    }

    private void doCondition( List<BaseColumn> allColumns,
                              Pattern52 pattern,
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.