Package cascading.pattern.model.tree.predicate.compound

Examples of cascading.pattern.model.tree.predicate.compound.AndPredicate


      switch( operator )
        {
        case OR:
          return new OrPredicate( predicates );
        case AND:
          return new AndPredicate( predicates );
        case XOR:
          return new XorPredicate( predicates );
        case SURROGATE:
          return new SurrogatePredicate( predicates );
        }
View Full Code Here


    }

  @Test
  public void testAnd()
    {
    Predicate andPredicate = new AndPredicate( new IsNotMissingPredicate( "var0" ), new EqualsToPredicate( "var1", "value" ) );

    assertTrue( new PredicateEvaluator( expectedFields, andPredicate ).evaluate( tupleEntry ) );
    }
View Full Code Here

    }

  @Test
  public void testOr()
    {
    Predicate orPredicate = new AndPredicate( new IsNotMissingPredicate( "var2" ), new EqualsToPredicate( "var1", "value" ) );

    assertTrue( !new PredicateEvaluator( expectedFields, orPredicate ).evaluate( tupleEntry ) );
    }
View Full Code Here

    }

  @Test
  public void testComplex()
    {
    Predicate complexPredicate = new AndPredicate(
      new IsNotMissingPredicate( "var0" ),
      new OrPredicate( new EqualsToPredicate( "var1", "value" ), new IsMissingPredicate( "var2" ) ) );

    assertTrue( new PredicateEvaluator( expectedFields, complexPredicate ).evaluate( tupleEntry ) );
    }
View Full Code Here

TOP

Related Classes of cascading.pattern.model.tree.predicate.compound.AndPredicate

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.