Export (0) Print
Expand All

DbExpressionBuilder Class

.NET Framework 4.5

Provides an API to construct DbExpressions and allows that API to be accessed as extension methods on the expression type itself.

System::Object
  System.Data.Common.CommandTrees.ExpressionBuilder::DbExpressionBuilder

Namespace:  System.Data.Common.CommandTrees.ExpressionBuilder
Assembly:  System.Data.Entity (in System.Data.Entity.dll)

[ExtensionAttribute]
public ref class DbExpressionBuilder abstract sealed

The DbExpressionBuilder type exposes the following members.

  NameDescription
Public propertyStatic memberFalseGets a DbConstantExpression with the Boolean value false.
Public propertyStatic memberTrueGets a DbConstantExpression with the Boolean value true.
Top

  NameDescription
Public methodStatic memberAggregate Creates a new DbFunctionAggregate.
Public methodStatic memberAggregateDistinctCreates a new DbFunctionAggregate that is applied in a distinct fashion.
Public methodStatic memberAll(DbExpression, Func<DbExpression, DbExpression>) Creates a new DbQuantifierExpression that determines whether the given predicate holds for all elements of the input set.
Public methodStatic memberAll(DbExpressionBinding, DbExpression) Creates a new DbQuantifierExpression that determines whether the given predicate holds for all elements of the input set.
Public methodStatic memberAnd Creates an DbAndExpression that performs the logical And of the left and right arguments.
Public methodStatic memberAny(DbExpression) Creates a new DbExpression that determines whether the specified set argument is non-empty.
Public methodStatic memberAny(DbExpression, Func<DbExpression, DbExpression>)Creates a new DbQuantifierExpression that determines whether the given predicate holds for any element of the input set.
Public methodStatic memberAny(DbExpressionBinding, DbExpression)Creates a new DbQuantifierExpression that determines whether the given predicate holds for any element of the input set.
Public methodStatic memberAs(DbAggregate, String)Returns the specified arguments as a key/value pair object.
Public methodStatic memberAs(DbExpression, String)Returns the specified arguments as a key/value pair object.
Public methodStatic memberBindCreates a new DbExpressionBinding that uses a generated variable name to bind the given expression.
Public methodStatic memberBindAsCreates a new DbExpressionBinding that uses the specified variable name to bind the given expression
Public methodStatic memberCaseCreates a new DbCaseExpression.
Public methodStatic memberCastToCreates a new DbCastExpression that applies a cast operation to a polymorphic argument.
Public methodStatic memberConstant(Object) Creates a new DbConstantExpression with the given constant value.
Public methodStatic memberConstant(TypeUsage, Object) Creates a new DbConstantExpression of the specified primitive type with the given constant value.
Public methodStatic memberCreateRef(EntitySet, IEnumerable<DbExpression>) Creates a new DbRefExpression that encodes a reference to a specific entity based on key values.
Public methodStatic memberCreateRef(EntitySet, array<DbExpression>) Creates a new DbRefExpression that encodes a reference to a specific entity based on key values.
Public methodStatic memberCreateRef(EntitySet, EntityType, IEnumerable<DbExpression>) Creates a new DbRefExpression that encodes a reference to a specific entity of a given type based on key values.
Public methodStatic memberCreateRef(EntitySet, EntityType, array<DbExpression>)Creates a new DbRefExpression that encodes a reference to a specific entity of a given type based on key values.
Public methodStatic memberCrossApply(DbExpression, Func<DbExpression, KeyValuePair<String, DbExpression>>) Creates a new DbApplyExpression that evaluates the given apply expression once for each element of a given input set, producing a collection of rows with corresponding input and apply columns. Rows for which apply evaluates to an empty set are not included.
Public methodStatic memberCrossApply(DbExpressionBinding, DbExpressionBinding) Creates a new DbApplyExpression that evaluates the given apply expression once for each element of a given input set, producing a collection of rows with corresponding input and apply columns. Rows for which apply evaluates to an empty set are not included.
Public methodStatic memberCrossJoinCreates a new DbCrossJoinExpression that unconditionally joins the sets specified by the list of input expression bindings.
Public methodStatic memberDerefCreates a new DbDerefExpression that retrieves a specific Entity given a reference expression.
Public methodStatic memberDistinct Creates a new DbDistinctExpression that removes duplicates from the given set argument.
Public methodStatic memberDivideCreates a new DbArithmeticExpression that divides the left argument by the right argument.
Public methodStatic memberElementCreates a new DbElementExpression that converts a set into a singleton.
Public methodStatic memberEqualCreates a new DbComparisonExpression that compares the left and right arguments for equality.
Public methodStatic memberExceptCreates a new DbExceptExpression that computes the subtraction of the right set argument from the left set argument.
Public methodStatic memberExistsCreates a new DbExpression that determines whether the specified set argument is non-empty.
Public methodStatic memberFilterCreates a new DbFilterExpression that filters the elements in the given input set using the specified predicate.
Public methodStatic memberFullOuterJoin(DbExpression, DbExpression, Func<DbExpression, DbExpression, DbExpression>) Creates a new DbJoinExpression that joins the sets specified by the left and right expressions, on the specified join condition, using FullOuterJoin as the DbExpressionKind.
Public methodStatic memberFullOuterJoin(DbExpressionBinding, DbExpressionBinding, DbExpression)Creates a new DbJoinExpression that joins the sets specified by the left and right expression bindings, on the specified join condition, using FullOuterJoin as the DbExpressionKind.
Public methodStatic memberGetEntityRefCreates a new DbEntityRefExpression that retrieves the ref of the specifed entity in structural form.
Public methodStatic memberGetRefKeyCreates a new DbRefKeyExpression that retrieves the key values of the specifed reference in structural form.
Public methodStatic memberGreaterThanCreates a new DbComparisonExpression that determines whether the left argument is greater than the right argument.
Public methodStatic memberGreaterThanOrEqualCreates a new DbComparisonExpression that determines whether the left argument is greater than or equal to the right argument.
Public methodStatic memberGroupBindCreates a new group expression binding that uses generated variable and group variable names to bind the given expression.
Public methodStatic memberGroupBindAsCreates a new DbGroupExpressionBinding that uses the specified variable name and group variable names to bind the given expression.
Public methodStatic memberGroupByCreates a new DbGroupByExpression that groups the elements of the input set according to the specified group keys and applies the given aggregates.
Public methodStatic memberInnerJoin(DbExpression, DbExpression, Func<DbExpression, DbExpression, DbExpression>) Creates a new DbJoinExpression that joins the sets specified by the left and right expressions, on the specified join condition, using InnerJoin as the DbExpressionKind.
Public methodStatic memberInnerJoin(DbExpressionBinding, DbExpressionBinding, DbExpression)Creates a new DbJoinExpression that joins the sets specified by the left and right expression bindings, on the specified join condition, using InnerJoin as the DbExpressionKind.
Public methodStatic memberIntersectCreates a new DbIntersectExpression that computes the intersection of the left and right set arguments.
Public methodStatic memberInvoke(DbLambda, IEnumerable<DbExpression>)Creates a new DbLambdaExpression representing the application of the specified Lambda function to the given arguments.
Public methodStatic memberInvoke(DbLambda, array<DbExpression>)Creates a new DbLambdaExpression representing the application of the specified Lambda function to the given arguments.
Public methodStatic memberInvoke(EdmFunction, IEnumerable<DbExpression>)Creates a new DbFunctionExpression representing the invocation of the specified function with the given arguments.
Public methodStatic memberInvoke(EdmFunction, array<DbExpression>)Creates a new DbFunctionExpression representing the invocation of the specified function with the given arguments.
Public methodStatic memberIsEmpty Creates a new DbIsEmptyExpression that determines whether the specified set argument is an empty set.
Public methodStatic memberIsNullCreates a new DbIsNullExpression that determines whether the specified argument is null.
Public methodStatic memberIsOfCreates a new DbIsOfExpression that determines whether the given argument is of the specified type or a subtype.
Public methodStatic memberIsOfOnlyCreates a new DbIsOfExpression expression that determines whether the given argument is of the specified type, and only that type (not a subtype).
Public methodStatic memberJoin(DbExpression, DbExpression, Func<DbExpression, DbExpression>, Func<DbExpression, DbExpression>)Creates a new DbJoinExpression that joins the sets specified by the outer and inner expressions, on an equality condition between the specified outer and inner keys, using InnerJoin as the DbExpressionKind.
Public methodStatic memberJoin<TSelector>(DbExpression, DbExpression, Func<DbExpression, DbExpression>, Func<DbExpression, DbExpression>, Func<DbExpression, DbExpression, TSelector>)Creates a new DbProjectExpression that projects the specified selector over the sets specified by the outer and inner expressions, joined on an equality condition between the specified outer and inner keys, using InnerJoin as the DbExpressionKind.
Public methodStatic memberLambda(DbExpression, IEnumerable<DbVariableReferenceExpression>)Creates a DbLambda with the specified inline Lambda function implementation and formal parameters.
Public methodStatic memberLambda(DbExpression, array<DbVariableReferenceExpression>)Creates a DbLambda with the specified inline Lambda function implementation and formal parameters.
Public methodStatic memberLeftOuterJoin(DbExpression, DbExpression, Func<DbExpression, DbExpression, DbExpression>)Creates a new DbJoinExpression that joins the sets specified by the left and right expressions, on the specified join condition, using LeftOuterJoin as the DbExpressionKind.
Public methodStatic memberLeftOuterJoin(DbExpressionBinding, DbExpressionBinding, DbExpression)Creates a new DbJoinExpression that joins the sets specified by the left and right expression bindings, on the specified join condition, using LeftOuterJoin as the DbExpressionKind.
Public methodStatic memberLessThanCreates a new DbComparisonExpression that determines whether the left argument is less than the right argument.
Public methodStatic memberLessThanOrEqualCreates a new DbComparisonExpression that determines whether the left argument is less than or equal to the right argument.
Public methodStatic memberLike(DbExpression, DbExpression) Creates a new DbLikeExpression that compares the specified input string to the given pattern.
Public methodStatic memberLike(DbExpression, DbExpression, DbExpression) Creates a new DbLikeExpression that compares the specified input string to the given pattern using the optional escape.
Public methodStatic memberLimit Creates a new DbLimitExpression that restricts the number of elements in the Argument collection to the specified count Limit value. Tied results are not included in the output.
Public methodStatic memberMinus Creates a new DbArithmeticExpression that subtracts the right argument from the left argument.
Public methodStatic memberModulo Creates a new DbArithmeticExpression that computes the remainder of the left argument divided by the right argument.
Public methodStatic memberMultiply Creates a new DbArithmeticExpression that multiplies the left argument by the right argument.
Public methodStatic memberNavigate(DbExpression, RelationshipEndMember, RelationshipEndMember)Creates a new DbRelationshipNavigationExpression representing the navigation of a composition or association relationship.
Public methodStatic memberNavigate(RelationshipType, String, String, DbExpression) Creates a new DbRelationshipNavigationExpression representing the navigation of a composition or association relationship.
Public methodStatic memberNegate Creates a new DbArithmeticExpression that negates the value of the argument.
Public methodStatic memberNew(TypeUsage, IEnumerable<DbExpression>) Creates a new DbNewInstanceExpression. If the type argument is a collection type, the arguments specify the elements of the collection. Otherwise the arguments are used as property or column values in the new instance.
Public methodStatic memberNew(TypeUsage, array<DbExpression>)Creates a new DbNewInstanceExpression. If the type argument is a collection type, the arguments specify the elements of the collection. Otherwise the arguments are used as property or column values in the new instance.
Public methodStatic memberNewCollection(array<DbExpression>)Creates a new DbNewInstanceExpression that constructs a collection containing the specified elements. The type of the collection is based on the common type of the elements. If no common element type exists an exception is thrown.
Public methodStatic memberNewCollection(IEnumerable<DbExpression>)Creates a new DbNewInstanceExpression that constructs a collection containing the specified elements. The type of the collection is based on the common type of the elements. If no common element type exists an exception is thrown.
Public methodStatic memberNewEmptyCollectionCreates a new DbNewInstanceExpression that constructs an empty collection of the specified collection type.
Public methodStatic memberNewRowCreates a new DbNewInstanceExpression that produces a row with the specified named columns and the given values, specified as expressions.
Public methodStatic memberNot Creates a DbNotExpression that performs the logical negation of the given argument.
Public methodStatic memberNotEqualCreates a new DbComparisonExpression that compares the left and right arguments for inequality.
Public methodStatic memberNullCreates a new DbNullExpression, which represents a typed null value.
Public methodStatic memberOfType Creates a new DbOfTypeExpression that produces a set consisting of the elements of the given input set that are of the specified type.
Public methodStatic memberOfTypeOnly Creates a new DbOfTypeExpression that produces a set consisting of the elements of the given input set that are of exactly the specified type.
Public methodStatic memberOrCreates an DbOrExpression that performs the logical Or of the left and right arguments.
Public methodStatic memberOrderBy(DbExpression, Func<DbExpression, DbExpression>)Creates a new DbSortExpression that sorts the given input set by the specified sort key, with ascending sort order and default collation.
Public methodStatic memberOrderBy(DbExpression, Func<DbExpression, DbExpression>, String)Creates a new DbSortExpression that sorts the given input set by the specified sort key, with ascending sort order and the specified collation.
Public methodStatic memberOrderByDescending(DbExpression, Func<DbExpression, DbExpression>)Creates a new DbSortExpression that sorts the given input set by the specified sort key, with descending sort order and default collation.
Public methodStatic memberOrderByDescending(DbExpression, Func<DbExpression, DbExpression>, String)Creates a new DbSortExpression that sorts the given input set by the specified sort key, with descending sort order and the specified collation.
Public methodStatic memberOuterApply(DbExpression, Func<DbExpression, KeyValuePair<String, DbExpression>>)Creates a new DbApplyExpression that evaluates the given apply expression once for each element of a given input set, producing a collection of rows with corresponding input and apply columns. Rows for which apply evaluates to an empty set have an apply column value of nullptr.
Public methodStatic memberOuterApply(DbExpressionBinding, DbExpressionBinding)Creates a new DbApplyExpression that evaluates the given apply expression once for each element of a given input set, producing a collection of rows with corresponding input and apply columns. Rows for which apply evaluates to an empty set have an apply column value of nullptr.
Public methodStatic memberParameterCreates a new DbParameterReferenceExpression that references a parameter with the specified name and type.
Public methodStatic memberPlusCreates a new DbArithmeticExpression that adds the left argument to the right argument.
Public methodStatic memberProjectCreates a new DbProjectExpression that projects the specified expression over the given input set.
Public methodStatic memberProperty(DbExpression, EdmProperty)Creates a new DbPropertyExpression representing the retrieval of the specified property.
Public methodStatic memberProperty(DbExpression, NavigationProperty)Creates a new DbPropertyExpression representing the retrieval of the specified navigation property.
Public methodStatic memberProperty(DbExpression, RelationshipEndMember)Creates a new DbPropertyExpression representing the retrieval of the specified relationship end member.
Public methodStatic memberProperty(DbExpression, String)Creates a new DbPropertyExpression representing the retrieval of the instance property with the specified name from the given instance.
Public methodStatic memberRefFromKey(EntitySet, DbExpression)Creates a new DbRefExpression that encodes a reference to a specific Entity based on key values.
Public methodStatic memberRefFromKey(EntitySet, DbExpression, EntityType)Creates a new DbRefExpression that encodes a reference to a specific Entity based on key values.
Public methodStatic memberScanCreates a new DbScanExpression that references the specified entity or relationship set.
Public methodStatic memberSelect<TProjection>Creates a new DbProjectExpression that selects the specified expression over the given input set.
Public methodStatic memberSelectMany(DbExpression, Func<DbExpression, DbExpression>)Creates a new DbApplyExpression that evaluates the given apply expression once for each element of a given input set, producing a collection of rows with corresponding input and apply columns. Rows for which apply evaluates to an empty set are not included. A DbProjectExpression is then created that selects the apply column from each row, producing the overall collection of apply results.
Public methodStatic memberSelectMany<TSelector>(DbExpression, Func<DbExpression, DbExpression>, Func<DbExpression, DbExpression, TSelector>)Creates a new DbApplyExpression that evaluates the given apply expression once for each element of a given input set, producing a collection of rows with corresponding input and apply columns. Rows for which apply evaluates to an empty set are not included. A DbProjectExpression is then created that selects the specified selector over each row, producing the overall collection of results.
Public methodStatic memberSkip(DbSortExpression, DbExpression)Creates a new DbSkipExpression that skips the specified number of elements from the given sorted input set.
Public methodStatic memberSkip(DbExpressionBinding, IEnumerable<DbSortClause>, DbExpression)Creates a new DbSkipExpression that sorts the given input set by the given sort specifications before skipping the specified number of elements.
Public methodStatic memberSortCreates a new DbSortExpression that sorts the given input set by the specified sort specifications.
Public methodStatic memberTakeCreates a new DbLimitExpression that restricts the number of elements in the Argument collection to the specified count Limit value. Tied results are not included in the output.
Public methodStatic memberThenBy(DbSortExpression, Func<DbExpression, DbExpression>)Creates a new DbSortExpression that with a sort order that includes the sort order of the given order input set together with the specified sort key in ascending sort order and with default collation.
Public methodStatic memberThenBy(DbSortExpression, Func<DbExpression, DbExpression>, String)Creates a new DbSortExpression that with a sort order that includes the sort order of the given order input set together with the specified sort key in ascending sort order and with the specified collation.
Public methodStatic memberThenByDescending(DbSortExpression, Func<DbExpression, DbExpression>)Creates a new DbSortExpression that with a sort order that includes the sort order of the given order input set together with the specified sort key in descending sort order and with default collation.
Public methodStatic memberThenByDescending(DbSortExpression, Func<DbExpression, DbExpression>, String)Creates a new DbSortExpression that with a sort order that includes the sort order of the given order input set together with the specified sort key in descending sort order and with the specified collation.
Public methodStatic memberToSortClause(DbExpression)Creates a new DbSortClause with an ascending sort order and default collation.
Public methodStatic memberToSortClause(DbExpression, String)Creates a new DbSortClause with an ascending sort order and the specified collation.
Public methodStatic memberToSortClauseDescending(DbExpression)Creates a new DbSortClause with a descending sort order and default collation.
Public methodStatic memberToSortClauseDescending(DbExpression, String)Creates a new DbSortClause with a descending sort order and the specified collation.
Public methodStatic memberTreatAsCreates a new DbTreatExpression.
Public methodStatic memberUnaryMinusCreates a new DbArithmeticExpression that negates the value of the argument.
Public methodStatic memberUnionCreates a new DbExpression that computes the union of the left and right set arguments with duplicates removed.
Public methodStatic memberUnionAllCreates a new DbUnionAllExpression that computes the union of the left and right set arguments and does not remove duplicates.
Public methodStatic memberVariableCreates a new DbVariableReferenceExpression that references a variable with the specified name and type.
Public methodStatic memberWhereCreates a new DbFilterExpression that filters the elements in the given input set using the specified predicate.
Top

.NET Framework

Supported in: 4.5.3

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show:
© 2014 Microsoft