com.esri.arcgis.carto
Class IMaps2Proxy

java.lang.Object
  extended by com.esri.arcgis.interop.Dispatch
      extended by com.esri.arcgis.carto.IMaps2Proxy
All Implemented Interfaces:
IMaps2, Externalizable, Serializable

public class IMaps2Proxy
extends com.esri.arcgis.interop.Dispatch
implements IMaps2, Serializable

Provides access to members of map collection.

Remarks

Every map document contains at least one Map object but a map document can contain any number of Map objects. The Maps object contains a collection of all the maps of the document. IMxDocument::Maps returns a reference to this collection.

The IMaps2 interface is a collection of map objects and contains method and properties to manage the maps contained by the document.

Only one Map can have focus at a time, and this Map is called the focus map. IMxDocument::FocusMap returns a reference to the Map currently with focus.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.esri.arcgis.interop.Dispatch
DISPATCH_METHOD, DISPATCH_PROPERTYGET, DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF, E
 
Constructor Summary
  IMaps2Proxy()
           
  IMaps2Proxy(Object obj)
           
protected IMaps2Proxy(Object obj, String iid)
           
 
Method Summary
 void add(IMap map)
          Adds a map to the collection.
 void addListener(String iidStr, Object theListener, Object theSource)
           
 IMap create()
          Creates a new map.
 int getCount()
          Number of maps.
 IMap getItem(int index)
          The map at the given index.
 void moveItem(IMap pMap, int toIndex)
          Moves the map to the given index.
 void readExternal(ObjectInput in)
           
 void remove(IMap map)
          Removes a map from the collection.
 void removeAt(int index)
          Removes a map at the specified index.
 void removeListener(String iidStr, Object theListener)
           
 void reset()
          Removes all maps from the collection.
 void writeExternal(ObjectOutput out)
           
 
Methods inherited from class com.esri.arcgis.interop.Dispatch
bindUsingMoniker, constructVtblPosTable, convertToNative, cookieForListener, createDispatch, createObjrefMonikerDisplayName, equals, getActiveObject, getActiveObject, getDefaultProperty, getDispatchIdOfName, getLastErrorCode, getMtsObjectContext, getObjRef, getPropertyByName, getPropertyByName, getVtblPos, hashCode, initDispatch, invoke, invokeMethodByName, invokeMethodByName, invokeMethodByName, invokePropertyGetByName, invokePropertyPutByName, invokePropertyPutByRefByName, isNativeMode, isObjRef, queryInterface, release, setNativeMode, setPropertyByName, toString, vtblInvoke
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IMaps2Proxy

public IMaps2Proxy()

IMaps2Proxy

public IMaps2Proxy(Object obj)
            throws IOException
Throws:
IOException

IMaps2Proxy

protected IMaps2Proxy(Object obj,
                      String iid)
               throws IOException
Throws:
IOException
Method Detail

addListener

public void addListener(String iidStr,
                        Object theListener,
                        Object theSource)
                 throws IOException
Overrides:
addListener in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

removeListener

public void removeListener(String iidStr,
                           Object theListener)
                    throws IOException
Overrides:
removeListener in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

getCount

public int getCount()
             throws IOException,
                    AutomationException
Number of maps.

Remarks

The Count property returns the number of Map objects in the collection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getCount in interface IMaps2
Returns:
The count
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getItem

public IMap getItem(int index)
             throws IOException,
                    AutomationException
The map at the given index.

Product Availability

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

Specified by:
getItem in interface IMaps2
Parameters:
index - The index (in)
Returns:
A reference to a com.esri.arcgis.carto.IMap
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

create

public IMap create()
            throws IOException,
                   AutomationException
Creates a new map.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

remove

public void remove(IMap map)
            throws IOException,
                   AutomationException
Removes a map from the collection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
remove in interface IMaps2
Parameters:
map - A reference to a com.esri.arcgis.carto.IMap (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

add

public void add(IMap map)
         throws IOException,
                AutomationException
Adds a map to the collection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
add in interface IMaps2
Parameters:
map - A reference to a com.esri.arcgis.carto.IMap (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

removeAt

public void removeAt(int index)
              throws IOException,
                     AutomationException
Removes a map at the specified index.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

reset

public void reset()
           throws IOException,
                  AutomationException
Removes all maps from the collection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

moveItem

public void moveItem(IMap pMap,
                     int toIndex)
              throws IOException,
                     AutomationException
Moves the map to the given index.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
moveItem in interface IMaps2
Parameters:
pMap - A reference to a com.esri.arcgis.carto.IMap (in)
toIndex - The toIndex (in)
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
Overrides:
writeExternal in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

readExternal

public void readExternal(ObjectInput in)
                  throws IOException,
                         ClassNotFoundException
Specified by:
readExternal in interface Externalizable
Overrides:
readExternal in class com.esri.arcgis.interop.Dispatch
Throws:
IOException
ClassNotFoundException