com.esri.arcgis.geodatabase
Interface IWorkspaceFactoryStatus

All Superinterfaces:
Serializable
All Known Implementing Classes:
SdeWorkspaceFactory

public interface IWorkspaceFactoryStatus
extends Serializable

Provides access to members that manage workspace status information.

Remarks

The IWorkspaceFactoryStatus interface is supported on SdeWorkspaceFactory objects and provides the capability to report on the status of a particular workspace. The ability to reconnect to a interrupted connect is also provided through this interface. This interface is useful in applications that need to check for interruptions in workspace connections. Such interruptions may be due to the SDE server being shutdown, or a network interruption between the client and the SDE server.

The WorkspaceStatus property returns an enumeration of IWorkspaceStatus objects for all currently open workspaces. This property should be used as a course grained object to determine the current status of the workspace connection (esriWCSUp or esriWCSDown). Use IWorkspaceStatus::ConnectionStatus property to determine the status of a particular workspace. The values of esriWorkspaceConnectionStatus returned by the WorkspaceStatus property are:

· esriWCSUp indicates that the workspace is up.

· esriWCSDown indicates that the workspace has lost its connection.

If the status of a workspace connection is esriWCSDown a reconnection can be made to the workspace once the workspace becomes available for reconnection. It is recommended to use the PingWorkspaceStatus method to obtain the current status of the down workspace. If the connection status has changed from esriWCSDown to esriWCSAvailable the OpenAvailableWorkspace method can be used to get a reference to the workspace.

Note that OpenAvailableWorkspace does not repair the original workspace, but provides a mechanism to get a new one when reconnection is possible. It is the responsibility of the application to refresh other objects that rely on the new workspace (for example, opening a feature class from the new workspace and setting it into a feature layer).

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.


Method Summary
 IEnumWorkspaceStatus getWorkspaceStatus()
          Retrieve the workspace status information for all currently opened workspaces.
 IWorkspace openAvailableWorkspace(IWorkspaceStatus wstatus)
          Makes an attempt to open a new instance of a workspace that is esriWCSDown but has since become esriWCSAvailable.
 IWorkspaceStatus pingWorkspaceStatus(IWorkspace workspace)
          Checks if the status of an esriWCSDown workspace has changed.
 

Method Detail

getWorkspaceStatus

IEnumWorkspaceStatus getWorkspaceStatus()
                                        throws IOException,
                                               AutomationException
Retrieve the workspace status information for all currently opened workspaces.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Returns:
A reference to a com.esri.arcgis.geodatabase.IEnumWorkspaceStatus
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

pingWorkspaceStatus

IWorkspaceStatus pingWorkspaceStatus(IWorkspace workspace)
                                     throws IOException,
                                            AutomationException
Checks if the status of an esriWCSDown workspace has changed.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
workspace - A reference to a com.esri.arcgis.geodatabase.IWorkspace (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IWorkspaceStatus
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

openAvailableWorkspace

IWorkspace openAvailableWorkspace(IWorkspaceStatus wstatus)
                                  throws IOException,
                                         AutomationException
Makes an attempt to open a new instance of a workspace that is esriWCSDown but has since become esriWCSAvailable.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
wstatus - A reference to a com.esri.arcgis.geodatabase.IWorkspaceStatus (in)
Returns:
A reference to a com.esri.arcgis.geodatabase.IWorkspace
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.