ObjectQuery Class
Implements common functionality for queries against a conceptual model using both LINQ to Entities and ObjectQuery<T>.
Assembly: System.Data.Entity (in System.Data.Entity.dll)
| Name | Description | |
|---|---|---|
![]() | CommandText | Returns the command text for the query. |
![]() | Context | Gets the object context associated with this object query. |
![]() | EnablePlanCaching | Gets or sets a value that indicates whether the query plan should be cached. |
![]() | MergeOption | Gets or sets how objects returned from a query are added to the object context. |
![]() | Parameters | Gets the parameter collection for this object query. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object^) | Determines whether the specified object is equal to the current object.(Inherited from Object.) |
![]() | Execute(MergeOption) | Executes the untyped object query with the specified merge option. |
![]() | Finalize() | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.) |
![]() | GetHashCode() | Serves as the default hash function. (Inherited from Object.) |
![]() | GetResultType() | Returns information about the result type of the query. |
![]() | GetType() | |
![]() | MemberwiseClone() | |
![]() | ToString() | Returns a string that represents the current object.(Inherited from Object.) |
![]() | ToTraceString() | Returns the commands to execute against the data source. |
| Name | Description | |
|---|---|---|
![]() ![]() | IEnumerable::GetEnumerator() | Returns an enumerator that iterates through a collection. |
![]() ![]() | IListSource::GetList() | Returns the collection as an IList used for data binding. |
![]() ![]() | IListSource::ContainsListCollection | Gets a value that indicates whether the collection returned by the query contains collection objects. |
![]() ![]() | IQueryable::ElementType | Gets the result element type for this query instance. |
![]() ![]() | IQueryable::Expression | Gets the expression describing this query. |
![]() ![]() | IQueryable::Provider | Gets the LINQ IQueryProvider associated with this query instance. |
| Name | Description | |
|---|---|---|
![]() | AsParallel() | Overloaded. Enables parallelization of a query.(Defined by ParallelEnumerable.) |
![]() | AsQueryable() | Overloaded. Converts an IEnumerable to an IQueryable.(Defined by Queryable.) |
![]() | Cast<TResult>() | Casts the elements of an IEnumerable to the specified type.(Defined by Enumerable.) |
![]() | OfType<TResult>() | Filters the elements of an IEnumerable based on a specified type.(Defined by Enumerable.) |
ObjectQuery is the base class for queries against a conceptual model. ObjectQuery is provided to ensure that LINQ to Entities queries have the same functionality as queries executed using ObjectQuery<T>. You must use ObjectQuery<T> with a specified type to query a conceptual model. For more information, see Object Queries.
Available since 3.5
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.





