DevForce Help Reference
EntityManager Class Methods


For a list of all members of this type, see EntityManager members.

Public Methods
 NameDescription
Public MethodAcceptChanges Accept changes to all modified, deleted or added entities within the cache.  
Public MethodAddEntitiesAdds newly created entities to the EntityManager cache.  
Public MethodAddEntityAdds a newly created entity to the EntityManager cache.  
Public MethodAttachEntities Adds a collection of detached entities to this EntityManager and marks them with the specified EntityState. Throws an exception if an entity with the same key already exists in the manager or if the specified entities are not in a detached state.  
Public MethodAttachEntity Adds a detached entity to this EntityManager and marks it with the specified EntityState. Throws an exception if an entity with the same key already exists in the manager or if the specified entity is not in a detached state.  
Public MethodClear Resets the EntityManager to its initial "newed" state.  
Public MethodConnectConnect to the IdeaBlade.EntityModel.Server.EntityServer.  
Public MethodConnectAsyncOverloaded. ConnectAsync(CancellationToken) with System.Threading.CancellationToken.None  
Public MethodCreateEntityOverloaded. Create a new entity of the requested type.  
Public MethodDisconnectDisconnect from the IdeaBlade.EntityModel.Server.EntityServer.  
Public MethodEquals (Inherited from object)
Public MethodExecuteQueryOverloaded.  Executes the specified query.  
Public MethodExecuteQueryAsyncOverloaded.  Executes the specified query asynchronously.  
Public MethodExecuteQueryForObject Executes the specified query returning a scalar value.  
Public MethodExecuteQueryForObjectAsyncOverloaded.  Executes the specified scalar query asynchronously.  
Public MethodFindEntitiesOverloaded.  Find all entities in cache having the specified entity state(s).  
Public MethodFindEntityOverloaded. Finds the object in cache using the EntityKey provided.  
Public MethodFindEntityGraph Given any entity or entities in a graph, collects and retrieves all related entities in the graph. This is a cache-only operation.  
Public MethodForceIdFixup Force an immediate update of all auto-generated IDs.  
Public MethodForceIdFixupAsyncPerform an asynchronous ForceIdFixup operation.  
Public MethodGenerateIdGenerates a temporary ID for an IEntity. The temporary ID will be mapped to a real ID when SaveChanges is called.  
Public MethodGetEntityGroupOverloaded.  Returns the EntityGroup associated with a specific Entity subtype.  
Public MethodGetEntityGroupsCollection of all EntityGroups within the cache.  
Public MethodGetHashCode (Inherited from object)
Public MethodGetNullEntityOverloaded.  Returns a "null" entity of the specified entity type.  
Public MethodGetQueryOverloaded.  Return an EntityQuery to retrieve entities of the specified type.  
Public MethodGetType (Inherited from object)
Public MethodHasChanges Determines whether the EntityManager cache has any changes that have not yet been persisted to the backend data source.  
Public MethodImportEntities Import entities from another EntityManager into this one.  
Public MethodInvokeServerMethodOverloaded. Invokes the specified static (Shared in Visual Basic) method for execution on the server.  
Public MethodInvokeServerMethodAsyncOverloaded. Calls InvokeServerMethodAsync(ServerMethodDelegate,CancellationToken,Object[]) with System.Threading.CancellationToken.None  
Public MethodIsEntityLoaded Returns true if the Entity is in cache.  
Public MethodIsEntityType Determines if the specified type is an entity type.  
Public MethodRefetchEntitiesOverloaded.  Forces a collection of entities to be refetched from the backend data source.  
Public MethodRefetchEntitiesAsyncOverloaded.  Forces a collection of entities to be refetched from the backend data source.  
Public MethodRefetchEntity Forces an entity to be refetched from the backend data source.  
Public MethodRefetchEntityAsyncOverloaded. Calls RefetchEntityAsync(Object,MergeStrategy,CancellationToken) with System.Threading.CancellationToken.None  
Public MethodRejectChangesRolls back all Entity changes since the cache was created or the last SaveChanges call was made.  
Public MethodRemoveEntitiesOverloaded. Removes a collection of entities from the EntityManager cache.  
Public MethodRemoveEntityRemoves an IEntity from the EntityManager cache.  
Public MethodSaveChangesPersists all changed entities within the EntityManager cache to the backend data source using the SaveOptions specified.  
Public MethodSaveChangesAsyncPerform an asynchronous SaveChanges operation with the specified SaveOptions.  
Public MethodToString (Inherited from object)
Public MethodTryExecuteQueryOverloaded. Executes the specified query and returns a QueryResult.  
Public MethodTryExecuteQueryAsyncOverloaded. Executes the specified query asynchronously and returns a QueryResult.  
Public MethodTrySaveChangesPersists one or more selected Entities within the EntityManager cache to the backend data source using the SaveOptions specified.  
Public MethodTrySaveChangesAsyncPerform an asynchronous SaveChanges operation with the specified SaveOptions.  
Top
Protected Methods
 NameDescription
Protected MethodFinalize (Inherited from object)
Protected MethodMemberwiseClone (Inherited from object)
Protected MethodOnClearedRaises the Cleared event.  
Protected MethodOnConnectionStateChangedRaises the ConnectionStateChanged event.  
Protected Methodstatic (Shared in Visual Basic)OnEntityManagerCreatedRaises the EntityManagerCreated event.  
Protected MethodOnFetchingRaises the Fetching event.  
Protected MethodOnQueriedRaises the Queried event.  
Protected MethodOnQueryingRaises the Querying event.  
Protected MethodOnSavedRaises the Saved event.  
Protected MethodOnSavingRaises the Saving event.  
Top
Extension Methods
 NameDescription
Public Extension MethodConnectAsyncConnect to the IdeaBlade.EntityModel.Server.EntityServer asynchronously.
Public Extension MethodExecuteQueryAsyncOverloaded.  Execute a query asynchronously.
Public Extension MethodForceIdFixupAsyncPerform an asynchronous ForceIdFixup operation.
Public Extension MethodInvokeServerMethodAsyncOverloaded. Asynchronously invokes the specified static (Shared in Visual Basic) method for execution on the server.
Public Extension MethodRefetchEntitiesAsyncOverloaded.  Performs an asynchronous refetch of all entities with the specified EntityState(s) from the backend data source.
Public Extension MethodRefetchEntityAsync Perform an asynchronous refetch operation.
Public Extension MethodSaveChangesPersists one or more selected Entities within the EntityManager cache to the backend data source using the IdeaBlade.EntityModel.SaveOptions specified.
Public Extension MethodSaveChangesAsyncOverloaded. Perform an asynchronous SaveChanges operation.
Public Extension MethodSaveChangesAsyncPerform an asynchronous IdeaBlade.EntityModel.Compat.EntityManagerPartialSaveExtensions.SaveChanges(IdeaBlade.EntityModel.EntityManager,System.Collections.IEnumerable,IdeaBlade.EntityModel.SaveOptions) operation with the specified list of entities and IdeaBlade.EntityModel.SaveOptions.
Public Extension MethodTrySaveChangesPersists one or more selected Entities within the EntityManager cache to the backend data source using the IdeaBlade.EntityModel.SaveOptions specified.
Public Extension MethodTrySaveChangesAsyncPerform an asynchronous IdeaBlade.EntityModel.Compat.EntityManagerPartialSaveExtensions.SaveChanges(IdeaBlade.EntityModel.EntityManager,System.Collections.IEnumerable,IdeaBlade.EntityModel.SaveOptions) operation with the specified list of entities and IdeaBlade.EntityModel.SaveOptions.
Top
See Also

Reference

EntityManager Class
IdeaBlade.EntityModel Namespace
IEntity Interface
EntityQuery Class
PassthruEsqlQuery Class
StoredProcQuery Class

Send Feedback