Examples of InvokeParentRule


Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        ReadContentRule rule = new ReadContentRule();
        rule.setPropertyName("value");

        em.addRule(rule);

        em.addRule(new InvokeParentRule("addElement"));

        SchemaImpl schema = new SchemaImpl();
        schema.addElementModel(em);
        schema.setModule(m);
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        ReadContentRule rule = new ReadContentRule();
        rule.setPropertyName("value");

        em.addRule(rule);

        em.addRule(new InvokeParentRule("addElement"));

        SchemaImpl schema = new SchemaImpl();
        schema.addElementModel(em);
        schema.setModule(m);
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        rule.setPropertyName("value");
        rule.setAttributeName("wife");

        em.addRule(rule);

        em.addRule(new InvokeParentRule("addElement"));

        SchemaImpl schema = new SchemaImpl();
        schema.addElementModel(em);
        schema.setModule(m);
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        ReadContentRule rule = new ReadContentRule();
        rule.setPropertyName("value");

        em.addRule(rule);

        em.addRule(new InvokeParentRule("addElement"));

        SchemaImpl schema = new SchemaImpl();
        schema.addElementModel(em);

        MockControl control = newControl(Module.class);
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        rule.setAttributeName("name");
        rule.setPropertyName("value");

        em.addRule(rule);

        em.addRule(new InvokeParentRule("addElement"));

        SchemaImpl schema = new SchemaImpl();
        schema.addElementModel(em);

        MockControl control1 = newControl(Module.class);
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        ReadContentRule rule3 = (ReadContentRule) rl.get(2);

        assertEquals("description", rule3.getPropertyName());

        InvokeParentRule rule4 = (InvokeParentRule) rl.get(3);

        assertEquals("addElement", rule4.getMethodName());
    }
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

                rule.setAttribute("class", cor.getClassName());
            }
            else if (r instanceof InvokeParentRule)
            {
                InvokeParentRule ipr = (InvokeParentRule) r;
                rule = _document.createElement("invoke-parent");

                rule.setAttribute("method", ipr.getMethodName());
                if (ipr.getDepth() != 1)
                    rule.setAttribute("depth", Integer.toString(ipr.getDepth()));
            }
            else if (r instanceof PushAttributeRule)
            {
                PushAttributeRule par = (PushAttributeRule) r;
                rule = _document.createElement("push-attribute");
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        SetModuleRule rule4 = (SetModuleRule) rl.get(3);

        assertEquals("module", rule4.getPropertyName());

        InvokeParentRule rule5 = (InvokeParentRule) rl.get(4);

        assertEquals("addElement", rule5.getMethodName());
    }
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

    }

    private void enterInvokeParent(String elementName)
    {
        ElementModelImpl elementModel = (ElementModelImpl) peekObject();
        InvokeParentRule rule = new InvokeParentRule();

        push(elementName, rule, STATE_NO_CONTENT);

        checkAttributes();

        rule.setMethodName(getAttribute("method"));
       
        if (_attributes.containsKey("parameter-count")) {
            rule.setParameterCount(getIntAttribute("parameter-count"));
        }

        if (_attributes.containsKey("depth"))
            rule.setDepth(getIntAttribute("depth"));

        elementModel.addRule(rule);
    }
View Full Code Here

Examples of org.apache.hivemind.schema.rules.InvokeParentRule

        _rules.add(new CreateObjectRule(_className));

        addAttributeRules();

        _rules.add(new InvokeParentRule(_parentMethodName));
    }
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.