Use the ISupportErrorInfo method InterfaceSupportsErrorInfo to determine if the object supports extended error information. If the object supports extended error info, VC++ developers should use the OLE/COM IErrorInfo interface to access the ErrorInfo object. Visual Basic developers should use the global error object Err to retrieve this extended error information.
|ISupportErrorInfo||Indicates whether a specific interface can return Automation error objects.|
|IWorkspaceFactory (esriGeoDatabase)||Provides access to members that create and open workspaces and supply workspace factory information.|
|IWorkspaceFactory2 (esriGeoDatabase)||Provides access to members that create and open workspaces and supply workspace factory information.|
An InMemoryWorkspaceFactory is used to connect to a temporary workspace which is stored in memory. These workspaces are commonly used to hold the results of an analysis operation or to hold objects in memory before persisting them to disk. When the last reference to the workspace is released, the workspace is destroyed and the memory released.
InMemory workspaces support tables and simple feature classes with geometries of point, multipoint, multipatch, polyline and polygon. Zs and Ms are supported. Feature classes and tables contained within InMemory workspaces support the full geodatabase model in terms of being used in conjunction with cursors, selections, etc.
What follows is a description of what is not supported by InMemory workspaces. This list may not be exhaustive as it reflects the most commonly used aspects of the Geodatabase data model. InMemory workspaces do not support the following:
The following example shows how to create an InMemory workspace.
// Create an in-memory workspace factory. IWorkspaceFactory workspaceFactory = new InMemoryWorkspaceFactoryClass(); // Create a new in-memory workspace. This returns a name object. IWorkspaceName workspaceName = workspaceFactory.Create(null, "MyWorkspace", null, 0); IName name = (IName)workspaceName; // Open the workspace through the name object. IWorkspace workspace = (IWorkspace)name.Open();