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

Examples of org.drools.workbench.models.datamodel.rule.FromEntryPointFactPattern


                } else if ( sender == fromAccumulateBtn ) {
                    getFromAccumulatePattern().setSourcePattern( new FromAccumulateCompositeFactPattern() );
                } else if ( sender == fromCollectBtn ) {
                    getFromAccumulatePattern().setSourcePattern( new FromCollectCompositeFactPattern() );
                } else if ( sender == fromEntryPointBtn ) {
                    getFromAccumulatePattern().setSourcePattern( new FromEntryPointFactPattern() );
                } else {
                    throw new IllegalArgumentException( "Unknown sender: "
                                                                + sender );
                }
View Full Code Here


        verify( constants ).FactType0HasAField1ThatHasAnOperatorSetButNoValuePleaseAddAValueOrRemoveTheOperator( "Address", "street" );
    }

    @Test
    public void testEmptyFromEntryPointFactPattern() throws Exception {
        model.lhs = new IPattern[]{ new FromEntryPointFactPattern() };

        assertFalse( validator.isValid() );
        assertEquals( 2, validator.getErrors().size() );
        assertEquals( MISSING_FACT_PATTERN, validator.getErrors().get( 0 ) );
        assertEquals( MISSING_ENTRY_POINT, validator.getErrors().get( 1 ) );
View Full Code Here

        verify( constants ).PleaseSetTheEntryPoint();
    }

    @Test
    public void testValidFromEntryPointFactPattern() throws Exception {
        FromEntryPointFactPattern fromEntryPointFactPattern = new FromEntryPointFactPattern();
        fromEntryPointFactPattern.setFactPattern( new FactPattern( "Person" ) );
        fromEntryPointFactPattern.setEntryPointName( "entryPoint" );
        model.lhs = new IPattern[]{ fromEntryPointFactPattern };

        assertTrue( validator.isValid() );
    }
View Full Code Here

TOP

Related Classes of org.drools.workbench.models.datamodel.rule.FromEntryPointFactPattern

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.