DevForce Help Reference
CompositePredicateDescription Class
Members  Example 


Represents the conditional And/Or of two dynamically built predicate clauses.
Syntax
'Declaration
 
Public Class CompositePredicateDescription 
'Usage
 
Dim instance As CompositePredicateDescription
public class CompositePredicateDescription 
Remarks
A CompositePredicateDescription is returned when using the DynamicQueryExtensions.And or DynamicQueryExtensions.Or methods, or by similar methods on the PredicateBuilder. You can build a filtered query using PredicateBuilder.FilterQuery or create a lambda expression from the predicate using ToLambdaExpression.
Example
public void PredicateBuilderMake() {
  var mgr = new DomainModelEntityManager();

  var expr1 = PredicateBuilder.Make(typeof(Product), "UnitPrice", FilterOperator.IsLessThanOrEqualTo, 10);
  var expr2 = PredicateBuilder.Make(typeof(Product), "Discontinued", FilterOperator.IsEqualTo, false);

  var results = mgr.Products.Where(expr1.And(expr2)).ToList();
}
Inheritance Hierarchy

System.Object
   IdeaBlade.Linq.CompositePredicateDescription

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

CompositePredicateDescription Members
IdeaBlade.Linq Namespace

Send Feedback