com.esri.arcgis.geodatabase
Interface IWorkspaceName

All Superinterfaces:
Serializable
All Known Subinterfaces:
IWorkspaceName2
All Known Implementing Classes:
WorkspaceName

public interface IWorkspaceName
extends Serializable

Provides access to members that supply workspace name information.

Superseded By

IWorkspaceName2

Remarks

The IWorkspaceName interface lets you access the properties of a workspace name. To work with a workspace name, you must first set the WorkspaceFactoryProgID property and either the PathName or ConnectionProperties property.

The workspace name can refer to an existing workspace, or one that has yet to be created. If the workspace already exists, it can be opened with IName::Open--effectively this procedure is equivalent to opening a workspace using Open or OpenFromFile on IWorkspaceFactory. If the workspace does not exist and is to be created, use IWorkspaceFactory::Create.

In some circumstances, you may already have a full workspace object but require a workspace name instead. You can retrieve the workspace name from a workspace by calling calling IDataset::FullName on the workspace.

The Type, Category, WorkspaceFactoryProgID, and BrowseName properties all return information on the workspace; refer to the documentation on IWorkspace.

When To Use

Use IWorkspaceName when you are browsing for workspaces and do not want the overhead of instantiating Workspace objects.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

See Also:
IGPDataType.getFullName()

Method Summary
 String getBrowseName()
          The browse name of the WorkspaceName.
 String getCategory()
          The category of the WorkspaceName.
 IPropertySet getConnectionProperties()
          The connection properties of the WorkspaceName.
 String getPathName()
          The path name of the WorkspaceName.
 int getType()
          The type of the associated workspace.
 IWorkspaceFactory getWorkspaceFactory()
          The workspace factory of the WorkspaceName.
 String getWorkspaceFactoryProgID()
          The ProgID of the WorkspaceName's workspace factory.
 void setBrowseName(String browseName)
          The browse name of the WorkspaceName.
 void setConnectionProperties(IPropertySet connectionProperties)
          The connection properties of the WorkspaceName.
 void setPathName(String pathName)
          The path name of the WorkspaceName.
 void setWorkspaceFactoryProgID(String progID)
          The ProgID of the WorkspaceName's workspace factory.
 

Method Detail

getPathName

String getPathName()
                   throws IOException,
                          AutomationException
The path name of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
The pathName
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setPathName

void setPathName(String pathName)
                 throws IOException,
                        AutomationException
The path name of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Parameters:
pathName - The pathName (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getWorkspaceFactoryProgID

String getWorkspaceFactoryProgID()
                                 throws IOException,
                                        AutomationException
The ProgID of the WorkspaceName's workspace factory.

Description

The WorkspaceFactoryProgID identifies the ProgID of the WorkspaceFactory object that is used to open that particular workspace.

Here is a list of some of the possible WorkspaceFactoryProgIDs:

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
The progID
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setWorkspaceFactoryProgID

void setWorkspaceFactoryProgID(String progID)
                               throws IOException,
                                      AutomationException
The ProgID of the WorkspaceName's workspace factory.

Description

The WorkspaceFactoryProgID identifies the ProgID of the COM WorkspaceFactory object used to open a workspace through a WorkspaceName object. You must set this property when you are using the WorkspaceName to open a workspace.

Here is a list of some of the possible WorkspaceFactoryProgIDs:

To set the WorkspaceName's WorkspaceFactoryProgID, simply pass it the string representing the correct type of workspace factory.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Parameters:
progID - The progID (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getBrowseName

String getBrowseName()
                     throws IOException,
                            AutomationException
The browse name of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
The browseName
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setBrowseName

void setBrowseName(String browseName)
                   throws IOException,
                          AutomationException
The browse name of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Parameters:
browseName - The browseName (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getWorkspaceFactory

IWorkspaceFactory getWorkspaceFactory()
                                      throws IOException,
                                             AutomationException
The workspace factory of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

setConnectionProperties

void setConnectionProperties(IPropertySet connectionProperties)
                             throws IOException,
                                    AutomationException
The connection properties of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Parameters:
connectionProperties - A reference to a com.esri.arcgis.system.IPropertySet (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getConnectionProperties

IPropertySet getConnectionProperties()
                                     throws IOException,
                                            AutomationException
The connection properties of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getType

int getType()
            throws IOException,
                   AutomationException
The type of the associated workspace.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
A com.esri.arcgis.geodatabase.esriWorkspaceType constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCategory

String getCategory()
                   throws IOException,
                          AutomationException
The category of the WorkspaceName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Returns:
The category
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.