com.esri.arcgis.gisclient
Class AGSServerConnectionName

java.lang.Object
  extended by com.esri.arcgis.gisclient.AGSServerConnectionName
All Implemented Interfaces:
IAGSServerConnectionName, IAGSServerConnectionName2, com.esri.arcgis.interop.RemoteObjRef, IName, IPersist, IPersistStream, Externalizable, Serializable

public class AGSServerConnectionName
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, IAGSServerConnectionName, IAGSServerConnectionName2, IName, IPersistStream, Externalizable

A name object for ArcGIS Server Connections.

Remarks

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

Example:

IName name = new FeatureClassName();

FeatureClass = name.Open();

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

See Also:
Serialized Form

Constructor Summary
AGSServerConnectionName()
          Constructs a AGSServerConnectionName using ArcGIS Engine.
AGSServerConnectionName(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
AGSServerConnectionName theAGSServerConnectionName = (AGSServerConnectionName) obj;
 
Method Summary
 boolean equals(Object o)
          Compare this object with another
 void getClassID(GUID[] pClassID)
          getClassID
static String getClsid()
          getClsid.
 IPropertySet getConnectionProperties()
          The connection properties of the AGSServerConnectionName.
 String getConnectionString()
          The connection properties of the GIS server connection.
 int getConnectionType()
          The type of the associated GIS server connection.
 String getNameString()
          The name string of the object.
 String getServerConnectionFactoryProgID()
          The programmatic ID of the server connection factory.
 void getSizeMax(_ULARGE_INTEGER[] pcbSize)
          getSizeMax
 int hashCode()
          the hashcode for this object
 void isDirty()
          isDirty
 void load(IStream pstm)
          load
 Object open()
          Opens the object referred to by this name.
 void readExternal(ObjectInput in)
           
 void save(IStream pstm, int fClearDirty)
          save
 void setConnectionProperties(IPropertySet ppConnProps)
          The connection properties of the AGSServerConnectionName.
 void setConnectionString(String connString)
          The connection properties of the GIS server connection.
 void setNameString(String nameString)
          The name string of the object.
 void setServerConnectionFactoryProgID(String progID)
          The programmatic ID of the server connection factory.
 void writeExternal(ObjectOutput out)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef
getJintegraDispatch, release
 

Constructor Detail

AGSServerConnectionName

public AGSServerConnectionName()
                        throws IOException,
                               UnknownHostException
Constructs a AGSServerConnectionName using ArcGIS Engine.

Throws:
IOException - if there are interop problems
UnknownHostException - if there are interop problems

AGSServerConnectionName

public AGSServerConnectionName(Object obj)
                        throws IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
AGSServerConnectionName theAGSServerConnectionName = (AGSServerConnectionName) obj;

Construct a AGSServerConnectionName using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to AGSServerConnectionName.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
IOException - if there are interop problems
Method Detail

getClsid

public static String getClsid()
getClsid.


equals

public boolean equals(Object o)
Compare this object with another

Overrides:
equals in class Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class Object

setConnectionProperties

public void setConnectionProperties(IPropertySet ppConnProps)
                             throws IOException,
                                    AutomationException
The connection properties of the AGSServerConnectionName.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setConnectionProperties in interface IAGSServerConnectionName
Parameters:
ppConnProps - 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

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

Remarks

The connection properties required in the property set depend on whether you are creating an AGSServerConnectionName which represents a direct connection to a GIS server over a LAN, or if it represetns a connection to a web service catalog. When connecting to a GIS server over the LAN, you need to set the machine property to be the name of the GIS server machine. When connecting to a web service catalog, you need to set the url property to the url of the web service catalog.

If the web service catalog you are connecting to is secure and requires a username and password, include them in the property set as the user and password properties, respectivly.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getConnectionProperties in interface IAGSServerConnectionName
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.

getConnectionType

public int getConnectionType()
                      throws IOException,
                             AutomationException
The type of the associated GIS server connection.

Remarks

The ConnectionType property will return the type of connection based on the property above. The connection types are described by esriAGSConnectionType whose values are esriAGSConnectionTypeLAN and esriAGSConnectionTypeInternet.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getConnectionType in interface IAGSServerConnectionName
Returns:
A com.esri.arcgis.gisclient.esriAGSConnectionType constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getConnectionString

public String getConnectionString()
                           throws IOException,
                                  AutomationException
The connection properties of the GIS server connection.

Product Availability

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

Specified by:
getConnectionString in interface IAGSServerConnectionName2
Returns:
The connString
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setConnectionString

public void setConnectionString(String connString)
                         throws IOException,
                                AutomationException
The connection properties of the GIS server connection.

Product Availability

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

Specified by:
setConnectionString in interface IAGSServerConnectionName2
Parameters:
connString - The connString (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getServerConnectionFactoryProgID

public String getServerConnectionFactoryProgID()
                                        throws IOException,
                                               AutomationException
The programmatic ID of the server connection factory.

Product Availability

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

Specified by:
getServerConnectionFactoryProgID in interface IAGSServerConnectionName2
Returns:
The progID
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setServerConnectionFactoryProgID

public void setServerConnectionFactoryProgID(String progID)
                                      throws IOException,
                                             AutomationException
The programmatic ID of the server connection factory.

Product Availability

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

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

setNameString

public void setNameString(String nameString)
                   throws IOException,
                          AutomationException
The name string of the object.

Remarks

The NameString property is reserved for future use. When implemented, it will return a string representation of the locational component of the name object that may be persisted by applications.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setNameString in interface IName
Parameters:
nameString - The nameString (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getNameString

public String getNameString()
                     throws IOException,
                            AutomationException
The name string of the object.

Remarks

The NameString property is reserved for future use. When implemented, it will return a string representation of the locational component of the name object that may be persisted by applications.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getNameString in interface IName
Returns:
The nameString
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

open

public Object open()
            throws IOException,
                   AutomationException
Opens the object referred to by this name.

Remarks

The Open method lets you instantiate the actual object given the name object.

Note: Opening a feature class that participates in a topology or geometric network will also open all other feature classes participating in the topology or geometric network in memory.

Example:

IName   pName = pFeatureClassName; 
pFeatureClass = new IFeatureClassProxy(pName.open());

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
open in interface IName
Returns:
A reference to another Object (IUnknown)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isDirty

public void isDirty()
             throws IOException,
                    AutomationException
isDirty

Description

IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isDirty in interface IPersistStream
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

load

public void load(IStream pstm)
          throws IOException,
                 AutomationException
load

Description

IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
load in interface IPersistStream
Parameters:
pstm - A reference to a com.esri.arcgis.system.IStream (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

save

public void save(IStream pstm,
                 int fClearDirty)
          throws IOException,
                 AutomationException
save

Description

IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
save in interface IPersistStream
Parameters:
pstm - A reference to a com.esri.arcgis.system.IStream (in)
fClearDirty - The fClearDirty (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSizeMax

public void getSizeMax(_ULARGE_INTEGER[] pcbSize)
                throws IOException,
                       AutomationException
getSizeMax

Description

IPersistStream is a Microsoft interface. Please refer to MSDN for information about this interface.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getSizeMax in interface IPersistStream
Parameters:
pcbSize - A Structure: com.esri.arcgis.system._ULARGE_INTEGER (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getClassID

public void getClassID(GUID[] pClassID)
                throws IOException,
                       AutomationException
getClassID

Description

IPersist is a Microsoft interface. Please refer to MSDN for information about this interface.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getClassID in interface IPersist
Parameters:
pClassID - A Structure: com.esri.arcgis.support.ms.stdole.GUID (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

writeExternal

public void writeExternal(ObjectOutput out)
                   throws IOException
Specified by:
writeExternal in interface Externalizable
Throws:
IOException

readExternal

public void readExternal(ObjectInput in)
                  throws IOException,
                         ClassNotFoundException
Specified by:
readExternal in interface Externalizable
Throws:
IOException
ClassNotFoundException