Package org.drools.reteoo

Examples of org.drools.reteoo.ReteooRuleBase$InitialFactHandleDummyObject


     *
     * @throws IntrospectionException
     */
    @Test
    public void testCompositeOrConstraint() {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final ClassFieldReader extractor = store.getReader( Cheese.class,
                                                            "type",
                                                            getClass().getClassLoader() );

View Full Code Here


     *
     * @throws IntrospectionException
     */
    @Test
    public void testNestedCompositeConstraints() {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final ClassFieldReader typeExtractor = store.getReader( Cheese.class,
                                                                "type",
                                                                getClass().getClassLoader() );

View Full Code Here

        rule.setLoadOrder( index );       
        final AgendaItem item = new AgendaItem( 0,
                                                null,
                                                0,
                                                null,
                                                new RuleTerminalNode(0, null, rule, new GroupElement(), new BuildContext( new ReteooRuleBase("x"), null )  ) );
        return item;
    }
View Full Code Here

     * doesn't need any requiredDeclarations
     *
     * @throws IntrospectionException
     */
    public void testLiteralConstraint() throws IntrospectionException {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final ClassFieldExtractor extractor = ClassFieldExtractorCache.getExtractor( Cheese.class,
                                                                                     "type",
                                                                                     getClass().getClassLoader()  );

View Full Code Here

     * </pre>
     *
     * @throws IntrospectionException
     */
    public void testPrimitiveLiteralConstraint() throws IntrospectionException {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final ClassFieldExtractor extractor = ClassFieldExtractorCache.getExtractor( Cheese.class,
                                                                                     "price",
                                                                                     getClass().getClassLoader() );

View Full Code Here

     * </pre>
     *
     * @throws IntrospectionException
     */
    public void testPredicateConstraint() throws IntrospectionException {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final FieldExtractor priceExtractor = ClassFieldExtractorCache.getExtractor( Cheese.class,
                                                                                     "price",
                                                                                     getClass().getClassLoader() );

View Full Code Here

     * </pre>
     *
     * @throws IntrospectionException
     */
    public void testReturnValueConstraint() throws IntrospectionException {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final FieldExtractor priceExtractor = ClassFieldExtractorCache.getExtractor( Cheese.class,
                                                                                     "price",
                                                                                     getClass().getClassLoader() );

View Full Code Here

     * used when nested inside other field constraints, as the top level AND is implicit
     *
     * @throws IntrospectionException
     */
    public void testCompositeAndConstraint() {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final ClassFieldExtractor extractor = ClassFieldExtractorCache.getExtractor( Cheese.class,
                                                                                     "type",
                                                                                     getClass().getClassLoader() );

View Full Code Here

     * Test the use of the composite OR constraint.
     *
     * @throws IntrospectionException
     */
    public void testCompositeOrConstraint() {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final ClassFieldExtractor extractor = ClassFieldExtractorCache.getExtractor( Cheese.class,
                                                                                     "type",
                                                                                     getClass().getClassLoader() );

View Full Code Here

     * Test the use of the composite OR constraint.
     *
     * @throws IntrospectionException
     */
    public void testNestedCompositeConstraints() {
        final ReteooRuleBase ruleBase = (ReteooRuleBase) RuleBaseFactory.newRuleBase();
        final InternalWorkingMemory workingMemory = (InternalWorkingMemory) ruleBase.newStatefulSession();

        final ClassFieldExtractor typeExtractor = ClassFieldExtractorCache.getExtractor( Cheese.class,
                                                                                         "type",
                                                                                         getClass().getClassLoader() );

View Full Code Here

TOP

Related Classes of org.drools.reteoo.ReteooRuleBase$InitialFactHandleDummyObject

Copyright © 2018 www.massapicom. 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.