com.esri.arcgis.carto
Class MapServerInfo

java.lang.Object
  extended by com.esri.arcgis.carto.MapServerInfo
All Implemented Interfaces:
IMapServerInfo, IMapServerInfo2, IMapServerInfo3, IMapServerInfo4, IMapServerTimeInfo, IMapServerTimeInfo2, com.esri.arcgis.interop.RemoteObjRef, IPersist, IPersistStream, IXMLSerialize, Externalizable, Serializable

public class MapServerInfo
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, IMapServerInfo, IMapServerInfo2, IXMLSerialize, IPersistStream, IPersist, IMapServerInfo3, IMapServerTimeInfo, IMapServerTimeInfo2, IMapServerInfo4, Externalizable

The Map Server Info coclass provides read-only information about a map.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

See Also:
Serialized Form

Constructor Summary
MapServerInfo()
          Constructs a MapServerInfo using ArcGIS Engine.
MapServerInfo(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
MapServerInfo theMapServerInfo = (MapServerInfo) obj;
 
Method Summary
 void deserialize(IXMLSerializeData data)
          Deserializes an object from XML.
 boolean equals(Object o)
          Compare this object with another
 IColor getBackgroundColor()
          The background color of the map (data frame).
 IFillSymbol getBackgroundSymbol()
          Background symbol of the map (data frame).
 IMapServerBookmarks getBookmarks()
          The published bookmarks for the map.
 void getClassID(GUID[] pClassID)
          getClassID
static String getClsid()
          getClsid.
 String getCopyrightText()
          Copyright information associated with the layer.
 IMapDescription getDefaultMapDescription()
          The default map settings.
 double getDefaultTimeInterval()
          The recommended default time interval to be used to animate the layer/table in the service.
 int getDefaultTimeIntervalUnits()
          The recommended default time interval units to be used to animate the layer/table in the service.
 double getDefaultTimeWindow()
          The recommended time window expressed in the same units as the time interval for the service.
 String getDescription()
          The description of the map (data frame).
 IEnvelope getExtent()
          The current extent of the map (data frame).
 IEnvelope getFullExtent()
          The full extent of the map (data frame).
 ITimeExtent getFullTimeExtent()
          TimeExtent of interest that the map as been authored.
 IMapLayerInfos getMapLayerInfos()
          A collection of Map Layer Info objects, each containing information about a layer in the map (data frame).
 int getMapUnits()
          The units for the map (data frame).
 double getMaxScale()
          The maximum visible scale for the service.
 double getMinScale()
          The minimum visible scale for the service.
 String getName()
          The name of the map (data frame).
 void getSizeMax(_ULARGE_INTEGER[] pcbSize)
          getSizeMax
 IStandaloneTableDescriptions getStandaloneTableDescriptions()
          Standalone tables descriptions that can passed in to other methods.
 IStandaloneTableInfos getStandaloneTableInfos()
          Standalone tables infromation in a given map.
 int hashCode()
          the hashcode for this object
 void isDirty()
          isDirty
 boolean isHasLiveData()
          Indicates whether the service is being updated frequently with new data.
 boolean isSupportsDynamicLayers()
          Indicates if this server supports per-request modification to layer properties.
 void load(IStream pstm)
          load
 void readExternal(ObjectInput in)
           
 void save(IStream pstm, int fClearDirty)
          save
 void serialize(IXMLSerializeData data)
          Serializes an object to XML.
 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

MapServerInfo

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

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

MapServerInfo

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

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

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

getName

public String getName()
               throws IOException,
                      AutomationException
The name of the map (data frame).

Remarks

If two (or more) data frames have the same name in the map document, MapServer adds a distinctive number at the end of the second name. E.g. Layers and Layers2.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getName in interface IMapServerInfo
Specified by:
getName in interface IMapServerInfo2
Specified by:
getName in interface IMapServerInfo3
Specified by:
getName in interface IMapServerInfo4
Returns:
The name
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDescription

public String getDescription()
                      throws IOException,
                             AutomationException
The description of the map (data frame). This property is set in the General tab of the Data Frame Properties dialog.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getDescription in interface IMapServerInfo
Specified by:
getDescription in interface IMapServerInfo2
Specified by:
getDescription in interface IMapServerInfo3
Specified by:
getDescription in interface IMapServerInfo4
Returns:
The desc
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFullExtent

public IEnvelope getFullExtent()
                        throws IOException,
                               AutomationException
The full extent of the map (data frame).

Remarks

The full extent of the map can either be the combined extent of all layers within the map or a custom full extent set by on the data frame by the author of the map document being served.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getFullExtent in interface IMapServerInfo
Specified by:
getFullExtent in interface IMapServerInfo2
Specified by:
getFullExtent in interface IMapServerInfo3
Specified by:
getFullExtent in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.geometry.IEnvelope
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getExtent

public IEnvelope getExtent()
                    throws IOException,
                           AutomationException
The current extent of the map (data frame).

Remarks

This is the extent of the DefaultMapDescription.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getExtent in interface IMapServerInfo
Specified by:
getExtent in interface IMapServerInfo2
Specified by:
getExtent in interface IMapServerInfo3
Specified by:
getExtent in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.geometry.IEnvelope
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMapLayerInfos

public IMapLayerInfos getMapLayerInfos()
                                throws IOException,
                                       AutomationException
A collection of Map Layer Info objects, each containing information about a layer in the map (data frame).

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getMapLayerInfos in interface IMapServerInfo
Specified by:
getMapLayerInfos in interface IMapServerInfo2
Specified by:
getMapLayerInfos in interface IMapServerInfo3
Specified by:
getMapLayerInfos in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.carto.IMapLayerInfos
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getBackgroundColor

public IColor getBackgroundColor()
                          throws IOException,
                                 AutomationException
The background color of the map (data frame).

Remarks

The background color is set in the map document itself. If background color is not explicitly set in the original mxd, the default color is set to an off-white color (RGB value of 253,253,253).

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getBackgroundColor in interface IMapServerInfo
Specified by:
getBackgroundColor in interface IMapServerInfo2
Specified by:
getBackgroundColor in interface IMapServerInfo3
Specified by:
getBackgroundColor in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.display.IColor
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getBookmarks

public IMapServerBookmarks getBookmarks()
                                 throws IOException,
                                        AutomationException
The published bookmarks for the map.

Remarks

Bookmarks are set in the map document itself.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getBookmarks in interface IMapServerInfo
Specified by:
getBookmarks in interface IMapServerInfo2
Specified by:
getBookmarks in interface IMapServerInfo3
Specified by:
getBookmarks in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.carto.IMapServerBookmarks
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDefaultMapDescription

public IMapDescription getDefaultMapDescription()
                                         throws IOException,
                                                AutomationException
The default map settings.

Remarks

The DefaultMapDescription refers to map settings set in the original map document. Changes to map settings using IMapDescription are temporary and do not affect the default map description returned by DefaultMapDescription.

The default settings for a MapServer object can be changed in two ways. First, you can make changes to the original map document and reinitialize the MapServer object. The other way to change the DefaultMapDescription is to use IMapServerObjects to access the fine-grained ArcObjects that the map settings are based, make the desired changes, and use the RefreshServerObjects method to overwite the old DefaultMapDescription with a new one. This should be done with objects in a non-pooled environment. Changing the state of pooled objects this way will lead to unexpected results.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getDefaultMapDescription in interface IMapServerInfo
Specified by:
getDefaultMapDescription in interface IMapServerInfo2
Specified by:
getDefaultMapDescription in interface IMapServerInfo3
Specified by:
getDefaultMapDescription in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.carto.IMapDescription
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMapUnits

public int getMapUnits()
                throws IOException,
                       AutomationException
The units for the map (data frame).

Remarks

The map units are set in the map document itself and cannot be changed using MapServer. The map's original spatial reference determines the units. Changing the SpatialReference property of IMapDescription will not change the value of the MapUnits property on IMapServerInfo.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getMapUnits in interface IMapServerInfo
Specified by:
getMapUnits in interface IMapServerInfo2
Specified by:
getMapUnits in interface IMapServerInfo3
Specified by:
getMapUnits in interface IMapServerInfo4
Returns:
A com.esri.arcgis.system.esriUnits constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getBackgroundSymbol

public IFillSymbol getBackgroundSymbol()
                                throws IOException,
                                       AutomationException
Background symbol of the map (data frame).

Remarks

If the background symbol and color are not explicitly set in the original map document (.mxd), the default background symbol is a polygon. The polygon will have a solid fill with an off-white color (RGB value of 253,253,253).

Product Availability

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

Specified by:
getBackgroundSymbol in interface IMapServerInfo2
Specified by:
getBackgroundSymbol in interface IMapServerInfo3
Specified by:
getBackgroundSymbol in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.display.IFillSymbol
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCopyrightText

public String getCopyrightText()
                        throws IOException,
                               AutomationException
Copyright information associated with the layer.

Product Availability

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

Specified by:
getCopyrightText in interface IMapServerInfo2
Specified by:
getCopyrightText in interface IMapServerInfo3
Specified by:
getCopyrightText in interface IMapServerInfo4
Returns:
The copyright
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

serialize

public void serialize(IXMLSerializeData data)
               throws IOException,
                      AutomationException
Serializes an object to XML.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

deserialize

public void deserialize(IXMLSerializeData data)
                 throws IOException,
                        AutomationException
Deserializes an object from XML.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
deserialize in interface IXMLSerialize
Parameters:
data - A reference to a com.esri.arcgis.system.IXMLSerializeData (in)
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.

getStandaloneTableInfos

public IStandaloneTableInfos getStandaloneTableInfos()
                                              throws IOException,
                                                     AutomationException
Standalone tables infromation in a given map.

Product Availability

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

Specified by:
getStandaloneTableInfos in interface IMapServerInfo3
Specified by:
getStandaloneTableInfos in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.carto.IStandaloneTableInfos
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getStandaloneTableDescriptions

public IStandaloneTableDescriptions getStandaloneTableDescriptions()
                                                            throws IOException,
                                                                   AutomationException
Standalone tables descriptions that can passed in to other methods.

Product Availability

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

Specified by:
getStandaloneTableDescriptions in interface IMapServerInfo3
Specified by:
getStandaloneTableDescriptions in interface IMapServerInfo4
Returns:
A reference to a com.esri.arcgis.carto.IStandaloneTableDescriptions
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFullTimeExtent

public ITimeExtent getFullTimeExtent()
                              throws IOException,
                                     AutomationException
TimeExtent of interest that the map as been authored.

Product Availability

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

Specified by:
getFullTimeExtent in interface IMapServerTimeInfo
Specified by:
getFullTimeExtent in interface IMapServerTimeInfo2
Returns:
A reference to a com.esri.arcgis.system.ITimeExtent
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDefaultTimeInterval

public double getDefaultTimeInterval()
                              throws IOException,
                                     AutomationException
The recommended default time interval to be used to animate the layer/table in the service.

Product Availability

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

Specified by:
getDefaultTimeInterval in interface IMapServerTimeInfo
Specified by:
getDefaultTimeInterval in interface IMapServerTimeInfo2
Returns:
The interval
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDefaultTimeIntervalUnits

public int getDefaultTimeIntervalUnits()
                                throws IOException,
                                       AutomationException
The recommended default time interval units to be used to animate the layer/table in the service.

Product Availability

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

Specified by:
getDefaultTimeIntervalUnits in interface IMapServerTimeInfo
Specified by:
getDefaultTimeIntervalUnits in interface IMapServerTimeInfo2
Returns:
A com.esri.arcgis.system.esriTimeUnits constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getDefaultTimeWindow

public double getDefaultTimeWindow()
                            throws IOException,
                                   AutomationException
The recommended time window expressed in the same units as the time interval for the service.

Product Availability

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

Specified by:
getDefaultTimeWindow in interface IMapServerTimeInfo
Specified by:
getDefaultTimeWindow in interface IMapServerTimeInfo2
Returns:
The duration
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isHasLiveData

public boolean isHasLiveData()
                      throws IOException,
                             AutomationException
Indicates whether the service is being updated frequently with new data.

Product Availability

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

Specified by:
isHasLiveData in interface IMapServerTimeInfo2
Returns:
The hasLiveData
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isSupportsDynamicLayers

public boolean isSupportsDynamicLayers()
                                throws IOException,
                                       AutomationException
Indicates if this server supports per-request modification to layer properties.

Remarks

It returns the value of enableDynamicLayers property set in a service configuration.

When this is true, the MapServer supports the following capabilities:

Product Availability

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

Specified by:
isSupportsDynamicLayers in interface IMapServerInfo4
Returns:
The supportsDynamicLayers
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMinScale

public double getMinScale()
                   throws IOException,
                          AutomationException
The minimum visible scale for the service.

Product Availability

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

Specified by:
getMinScale in interface IMapServerInfo4
Returns:
The scale
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMaxScale

public double getMaxScale()
                   throws IOException,
                          AutomationException
The maximum visible scale for the service.

Product Availability

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

Specified by:
getMaxScale in interface IMapServerInfo4
Returns:
The scale
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