com.esri.arcgis.gisclient
Interface IAGSServerConnection

All Superinterfaces:
Serializable
All Known Subinterfaces:
IAGSServerConnection2, IAGSServerConnection3
All Known Implementing Classes:
AGSServerConnection

public interface IAGSServerConnection
extends Serializable

Provides access to members that have information about the GIS server connection..

Superseded By

IAGSServerConnection2

Remarks

An AGSServerConnection is a connection to a GIS server or web service catalog. Both contain server objects such as MapServer and GeocodeServer server objects. IAGSServerConnection provides methods to get references to server objects the server or web service catalog.

The GetServerObjectNames method returns the AGSServerObjectName objects for all of the server objects in the GIS server or web service catalog.

The FullName property gets and sets the AGSServerConnectionName name object. The AGSServerConnectionName for an AGSServerConnection can be persisted, for example, in a map document. An application can call the Open method on the AGSServerConnection name after loading it from persistent storage in order to connect to and get an object reference to the GIS server or web service catalog.

The MapServer and GeocodeServer objects that you obtain from IAGSServerConnection support only the coarse-grained, stateless methods associated with the server object. You can't use a MapServer or GeocodeServer object obtained from IAGSServerConnection to get references to the finer-grained objects associated with the server object, not can you change any aspects of the server object's state. Server objects obtained from LAN connections or web service catalog AGSServerConnections can be used in the same way, so if you are writing applications that need to work with both LAN and web service catalog conneciton to a GIS server, use AGSServerConnection and its associated objects.

When you get a server object using the ArcCatalog objects (GxAGSServerConnection) and ArcMap (MapServerLayer ), you are working through an AGSServerConnection.

If you want to work with a server object in a stateful manner, or you want to work with the finer-grained ArcObjects associated with a server object, you must obtain that server object by getting a reference to its server context from the ServerObjectManager. You can get the ServerObjectManager by either connecting to the GIS server using a GISServerConnection object, or by getting it from the AGSServerConnection.

Product Availability

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

See Also:
IEnumServerObjectType, AGSLocatorWorkspace, IEnumServerObjectTypeInfo, GeocodeServer, ILocatorManager2.getAGSLocatorWorkspace(com.esri.arcgis.gisclient.IAGSServerConnectionName), ServerObject, ILocatorWorkspaceName2.getAGSServerConnectionName(), AGSAddressLocator

Method Summary
 IName getFullName()
          The AGSServerConnectionName object assiated with the GIS server connection.
 String getName()
          The name of the connection.
 IAGSEnumServerObjectName getServerObjectNames()
          The ServerObjectNames in the GIS server.
 void setFullNameByRef(IName ppNameObject)
          The AGSServerConnectionName object assiated with the GIS server connection.
 void setName(String name)
          The name of the connection.
 

Method Detail

setName

void setName(String name)
             throws IOException,
                    AutomationException
The name of the connection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getName

String getName()
               throws IOException,
                      AutomationException
The name of the connection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getServerObjectNames

IAGSEnumServerObjectName getServerObjectNames()
                                              throws IOException,
                                                     AutomationException
The ServerObjectNames in the GIS server.

Remarks

Returns an enumeration of the AGSServerObjectName objects in the GIS server or web service catalog. Note, if the application that uses this interface is running as a user in the GIS server's users group (agsusers), and connects directly to a GIS server over a LAN, this method will return only the server objects which are started. If the application that uses this interface is running as a user in the GIS server's administrators group (agsadmin), this method will return all server objects.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getFullName

IName getFullName()
                  throws IOException,
                         AutomationException
The AGSServerConnectionName object assiated with the GIS server connection.

Remarks

The FullName property gets and sets the AGSServerConnectionName name object. The AGSServerConnectionName for an AGSServerConnection can be persisted, for example, in a map document. An application can call the Open method on the AGSServerConnection name after loading it from persistent storage in order to connect to and get an object reference to the GIS server or web service catalog.

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.IName
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setFullNameByRef

void setFullNameByRef(IName ppNameObject)
                      throws IOException,
                             AutomationException
The AGSServerConnectionName object assiated with the GIS server connection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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