DataAccessAdapterCoreFetchEntityUsingUniqueConstraint Method (IEntity2, IPredicateExpression, IPrefetchPath2, Context, ExcludeIncludeFieldsList) |
Fetches an entity from the persistent storage into the object specified using the filter specified.
Use the entity's uniqueconstraint filter construction methods to construct the required uniqueConstraintFilter for the
unique constraint you want to use.
Namespace:
SD.LLBLGen.Pro.ORMSupportClasses
Assembly:
SD.LLBLGen.Pro.ORMSupportClasses (in SD.LLBLGen.Pro.ORMSupportClasses.dll) Version: 5.2.0.0 (5.2.17.0403)
Syntax public virtual bool FetchEntityUsingUniqueConstraint(
IEntity2 entityToFetch,
IPredicateExpression uniqueConstraintFilter,
IPrefetchPath2 prefetchPath,
Context contextToUse,
ExcludeIncludeFieldsList excludedIncludedFields
)
Public Overridable Function FetchEntityUsingUniqueConstraint (
entityToFetch As IEntity2,
uniqueConstraintFilter As IPredicateExpression,
prefetchPath As IPrefetchPath2,
contextToUse As Context,
excludedIncludedFields As ExcludeIncludeFieldsList
) As Boolean
Parameters
- entityToFetch
- Type: SD.LLBLGen.Pro.ORMSupportClassesIEntity2
The entity object in which the fetched entity data will be stored. - uniqueConstraintFilter
- Type: SD.LLBLGen.Pro.ORMSupportClassesIPredicateExpression
The filter which should filter on fields with a unique constraint. - prefetchPath
- Type: SD.LLBLGen.Pro.ORMSupportClassesIPrefetchPath2
The prefetch path to use for this fetch, which will fetch all related entities defined by the path as well. - contextToUse
- Type: SD.LLBLGen.Pro.ORMSupportClassesContext
The context to add the entity to if the fetch was succesful, and before the prefetch path is fetched. This ensures
that the prefetch path is fetched using the context specified and will re-use already loaded entity objects. - excludedIncludedFields
- Type: SD.LLBLGen.Pro.ORMSupportClassesExcludeIncludeFieldsList
The list of IEntityField2 objects which have to be excluded or included for the fetch.
If null or empty, all fields are fetched (default). If an instance of ExcludeIncludeFieldsList is passed in and its ExcludeContainedFields property
is set to false, the fields contained in excludedIncludedFields are kept in the query, the rest of the fields in the query are excluded.
Return Value
Type:
Booleantrue if the Fetch was succesful, false otherwise
Implements
IDataAccessAdapterFetchEntityUsingUniqueConstraint(IEntity2, IPredicateExpression, IPrefetchPath2, Context, ExcludeIncludeFieldsList)See Also