com.esri.arcgis.controls
Class IARMapProxy

java.lang.Object
  extended by com.esri.arcgis.interop.Dispatch
      extended by com.esri.arcgis.controls.IARMapProxy
All Implemented Interfaces:
IARMap, Externalizable, Serializable

public class IARMapProxy
extends com.esri.arcgis.interop.Dispatch
implements IARMap, Serializable

Provides access to members that control the ARMap.

Description

The IARMap interface is a starting point for navigating around the map, setting map properties, and accessing any layer's contained within the map.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

See Also:
Serialized Form

Field Summary
 boolean noncastable
           
 
Fields inherited from class com.esri.arcgis.interop.Dispatch
DISPATCH_METHOD, DISPATCH_PROPERTYGET, DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF, objRef
 
Constructor Summary
  IARMapProxy()
           
  IARMapProxy(Object obj)
           
protected IARMapProxy(Object obj, String iid)
           
 
Method Summary
 void addListener(String iidStr, Object theListener, Object theSource)
           
 void centerAt(double xCoord, double yCoord)
          Moves the center of the map to the specified point.
 void centerAtBookmark(Object vBookmarkID)
          Centers the map display on the bookmark.
 IARLayer getARLayer(int index)
          The layer at the specified index.
 int getARLayerCount()
          The number of layer in the map's layer collection.
 int getBookmarkCount()
          The number of bookmarks in the map's bookmark collection.
 String getBookmarkName(int index)
          The name of the bookmark.
 Object getCustomProperty()
          A property to associate data with an object.
 String getDescription()
          The description of the map.
 int getDistanceUnits()
          The distance units of the map.
 void getExtent(double[] xMin, double[] yMin, double[] xMax, double[] yMax)
          The visible extent of the map.
 void getFullExtent(double[] xMin, double[] yMin, double[] xMax, double[] yMax)
          The extent of all the data within the map.
 Object getInternalObject()
          The internal ArcObjects IMap object.
 double getMapScale()
          The scale of the map as a representative fraction.
 int getMapUnits()
          The geographical units of the map.
 String getName()
          The name of the map.
 double getReferenceScale()
          The reference scale of the map as a representative fraction.
 double getRotation()
          The number of degrees the map display is rotated.
 String getSpatialReferenceName()
          The name of the map's spatial reference.
 boolean isCanRedoExtent()
          Indicates if there is a map extent that can be redone.
 boolean isCanUndoExtent()
          Indicates if there is a map extent that can be undone.
 void pan(int direction, double screenPercentage)
          Pans the map by a factor in a specified direction.
 IARFeatureSet queryARFeatures(IARSearchDef pSearchDef)
          Searches the map using a search definition and returns an ARFeatureSet.
 void redoExtent()
          Redo the next map extent in the stack.
 void refresh(boolean refreshNow)
          Redraws the map display area.
 void removeListener(String iidStr, Object theListener)
           
 IARFeatureCursor searchARFeatures(IARSearchDef pSearchDef)
          Searches the map using a search definition and returns an ARFeatureCursor.
 void setCustomProperty(Object pVal)
          A property to associate data with an object.
 void setExtent(double xMin, double yMin, double xMax, double yMax)
          Sets the visible extent of the map.
 void setMapScale(double mapScale)
          The scale of the map as a representative fraction.
 void setRotation(double mapRotation)
          The number of degrees the map display is rotated.
 void toMapPoint(int x, int y, double[] xCoord, double[] yCoord)
          Converts a point in device coordinates (typically pixels) to coordinates in map units.
 void undoExtent()
          Undo to the previous map extent in the stack.
 void zoomIn(double factor)
          Zooms in on the map by a factor.
 void zoomOut(double factor)
          Zooms out on the map by a factor.
 void zoomToBookmark(Object vBookmarkID)
          Zooms the map display to the bookmark.
 void zoomToFullExtent()
          Zoom to the full extent of all data within the map.
 
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, optimizedVtblInvoke, queryInterface, readExternal, release, setNativeMode, setPropertyByName, toString, vtblInvoke, writeExternal
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

noncastable

public boolean noncastable
Constructor Detail

IARMapProxy

public IARMapProxy()

IARMapProxy

public IARMapProxy(Object obj)
            throws IOException
Throws:
IOException

IARMapProxy

protected IARMapProxy(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

setMapScale

public void setMapScale(double mapScale)
                 throws IOException,
                        AutomationException
The scale of the map as a representative fraction.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

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

getMapScale

public double getMapScale()
                   throws IOException,
                          AutomationException
The scale of the map as a representative fraction.

Description

The current scale of the ARMap. MapScale is the relationship between the dimensions of features on the ARMap and the geographic objects they represent on the earth, commonly expressed as a fraction or a ratio. A MapScale of 1/100,000 or 1:100,000 means that one unit of measure on the ARMap equals 100,000 of the same units on the earth. Some common scales are as follows:

Remarks

The MapScale property will return an error if the MapUnits are unknown or if passed a value of 0.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getMapScale in interface IARMap
Returns:
The mapScale
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#getSpatialReferenceName(), com.esri.arcgis.publishercontrols.IARMap#getReferenceScale(), com.esri.arcgis.publishercontrols.IARMap#getDistanceUnits(), com.esri.arcgis.publishercontrols.IARMap#getMapUnits()

refresh

public void refresh(boolean refreshNow)
             throws IOException,
                    AutomationException
Redraws the map display area.

Description

The Refresh method causes screen display area of the ARMap to be completely redrawn by sending a windows paint event. Use the Refresh method to ensure the ARMap is displaying the current state of the data. For example, if data is in an SDE server with many users editing the data, refreshing the ARMap ensures the user of a ArcReaderControl application sees any new edits.

Specify whether to immediately redraw the ARMap or whether to queue up the redraw to happen at some point in the immediate future. For example, if there are many extent changes, but only the last extent needs displaying to the user pass False to the Refresh method. The paint event will be queued and the ARMap will be redrawn once after the last extent change. However, if every extent change needs displaying to the user, pass True to the Refresh method. The ARMap will be redrawn after every extent change. Likewise pass True after an extent change, but before flashing or flickering an ARFeature.

Remarks

The Refresh method triggers the following events:

OnBeforeScreenDraw
OnAfterScreenDraw

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
refresh in interface IARMap
Parameters:
refreshNow - The refreshNow (in, optional, pass false if not required)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getName

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

Description

The Name of the ARMap. This is the name that appears in the Table of Contents (TOC) on the left hand side of the ArcReaderControl.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getName in interface IARMap
Returns:
The sName
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getARLayerCount

public int getARLayerCount()
                    throws IOException,
                           AutomationException
The number of layer in the map's layer collection.

Description

The ARLayerCount property returns the number of ARLayer's within the ARMap.

Remarks

This does not include any IARLayer::ChildARLayer objects if IARLayer::IsGroupLayer returns true for an ARLayer.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

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

getARLayer

public IARLayer getARLayer(int index)
                    throws IOException,
                           AutomationException
The layer at the specified index.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getARLayer in interface IARMap
Parameters:
index - The index (in)
Returns:
A reference to a com.esri.arcgis.controls.IARLayer
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.

Description

Returns a description of the ARMap at the time the document was published.

Remarks

Note that map's do not have a description by default.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getDescription in interface IARMap
Returns:
The sDesciption
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSpatialReferenceName

public String getSpatialReferenceName()
                               throws IOException,
                                      AutomationException
The name of the map's spatial reference.

Description

Returns the name of the spatial reference the ARMap is using to display data.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getSpatialReferenceName in interface IARMap
Returns:
The sSpatialReference
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#getReferenceScale(), com.esri.arcgis.publishercontrols.IARMap#getDistanceUnits()

getMapUnits

public int getMapUnits()
                throws IOException,
                       AutomationException
The geographical units of the map.

Description

The ARMap's map units. Any coordinates returned from the GetExtent, GetFullExtent and ToMapPoint methods will be in MapUnits. Likewise the coordinates passed into the SetExtent and CenterAt methods need to be in MapUnits.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getMapUnits in interface IARMap
Returns:
A com.esri.arcgis.controls.esriARUnits constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#getSpatialReferenceName(), com.esri.arcgis.publishercontrols.IARMap#getMapScale(), com.esri.arcgis.publishercontrols.IARMap#getReferenceScale(), com.esri.arcgis.publishercontrols.IARMap#getDistanceUnits()

getDistanceUnits

public int getDistanceUnits()
                     throws IOException,
                            AutomationException
The distance units of the map.

Description

The DistanceUnits are used when reporting measurements and are used by the esriARToolMapMeasure tool when it is set as the IARControl::CurrentARTool and is used on the ARMap object.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getDistanceUnits in interface IARMap
Returns:
A com.esri.arcgis.controls.esriARUnits constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#getSpatialReferenceName(), com.esri.arcgis.publishercontrols.IARMap#getMapScale(), com.esri.arcgis.publishercontrols.IARMap#getReferenceScale(), com.esri.arcgis.publishercontrols.IARMap#getMapUnits()

setExtent

public void setExtent(double xMin,
                      double yMin,
                      double xMax,
                      double yMax)
               throws IOException,
                      AutomationException
Sets the visible extent of the map.

Description

Sets the xmin, ymin, xmax and ymax coordinates of the ARMap's current visible extent in MapUnits. The SetExtent method automatically refreshes the ARMap's display area.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
setExtent in interface IARMap
Parameters:
xMin - The xMin (in)
yMin - The yMin (in)
xMax - The xMax (in)
yMax - The yMax (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#zoomToFullExtent(), com.esri.arcgis.publishercontrols.IARMap#getFullExtent(double[], double[], double[], double[]), com.esri.arcgis.publishercontrols.IARMap#getExtent(double[], double[], double[], double[])

getExtent

public void getExtent(double[] xMin,
                      double[] yMin,
                      double[] xMax,
                      double[] yMax)
               throws IOException,
                      AutomationException
The visible extent of the map.

Description

Returns the xmin, ymin, xmax and ymax coordinates of the ARMap's current visible extent in MapUnits.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getExtent in interface IARMap
Parameters:
xMin - The xMin (in/out: use single element array)
yMin - The yMin (in/out: use single element array)
xMax - The xMax (in/out: use single element array)
yMax - The yMax (in/out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#zoomToFullExtent(), com.esri.arcgis.publishercontrols.IARMap#setExtent(double, double, double, double), com.esri.arcgis.publishercontrols.IARMap#getFullExtent(double[], double[], double[], double[])

getFullExtent

public void getFullExtent(double[] xMin,
                          double[] yMin,
                          double[] xMax,
                          double[] yMax)
                   throws IOException,
                          AutomationException
The extent of all the data within the map.

Description

Returns the xmin, ymin, xmax and ymax coordinates of the full extent of all data layers in the ARMap in MapUnits.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getFullExtent in interface IARMap
Parameters:
xMin - The xMin (in/out: use single element array)
yMin - The yMin (in/out: use single element array)
xMax - The xMax (in/out: use single element array)
yMax - The yMax (in/out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#zoomToFullExtent(), com.esri.arcgis.publishercontrols.IARMap#setExtent(double, double, double, double), com.esri.arcgis.publishercontrols.IARMap#getExtent(double[], double[], double[], double[])

getReferenceScale

public double getReferenceScale()
                         throws IOException,
                                AutomationException
The reference scale of the map as a representative fraction.

Description

The ReferenceScale property indicates the scale to which all symbol and text sizes used in the ARMap will be made relative.

Remarks

A ReferenceScale set to 0 indicates that no ReferenceScale is set, and the size of any symbols or text on the ARMap will remain the same irrespective of MapScale. When a ReferenceScale is set, the size of any symbols or text on the ARMap will change as the MapScale changes. For example, text labels will get larger if you zoom in to a scale larger than the ReferenceScale and smaller if you zoom out to a scale smaller than the ReferenceScale.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getReferenceScale in interface IARMap
Returns:
The refScale
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#getSpatialReferenceName(), com.esri.arcgis.publishercontrols.IARMap#getDistanceUnits()

zoomIn

public void zoomIn(double factor)
            throws IOException,
                   AutomationException
Zooms in on the map by a factor.

Description

Zooms in on the ARMap from the center of its current visible extent by a specified factor. This factor represents the ratio between the new visible extent and the previous visible extent and will cause the MapScale property to change. For example, zooming in by a factor of 2, is the same as zooming out by a factor of 0.5 and vice versa.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
zoomIn in interface IARMap
Parameters:
factor - The factor (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#zoomOut(double), com.esri.arcgis.publishercontrols.IARMap#centerAt(double, double), com.esri.arcgis.publishercontrols.IARMap#pan(int, double)

zoomOut

public void zoomOut(double factor)
             throws IOException,
                    AutomationException
Zooms out on the map by a factor.

Description

Zooms out on the ARMap from the center of its current visible extent by a specified factor. This factor represents the ratio between the new visible extent and the previous visible extent and will cause the MapScale property to change. For example, zooming in by a factor of 2, is the same as zooming out by a factor of 0.5 and vice versa.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
zoomOut in interface IARMap
Parameters:
factor - The factor (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#zoomIn(double), com.esri.arcgis.publishercontrols.IARMap#centerAt(double, double), com.esri.arcgis.publishercontrols.IARMap#pan(int, double)

pan

public void pan(int direction,
                double screenPercentage)
         throws IOException,
                AutomationException
Pans the map by a factor in a specified direction.

Description

Pans the ARMap display area in the specified direction, by a specified screen percentage. The extent of the ARMap will change, but the MapScale will remain the same.

A percentage of 0 will not actually offset the ARMap in the display area, a percentage of 25 will pan the current visible extent by a quarter of its width, and a percentage of 100 will offset the ARMap in the display area completely, so that any of the ARMap visible before the Pan will no longer be visible.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
pan in interface IARMap
Parameters:
direction - A com.esri.arcgis.controls.esriARDirection constant (in)
screenPercentage - The screenPercentage (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#zoomIn(double), com.esri.arcgis.publishercontrols.IARMap#zoomOut(double), com.esri.arcgis.publishercontrols.IARMap#centerAt(double, double)

centerAt

public void centerAt(double xCoord,
                     double yCoord)
              throws IOException,
                     AutomationException
Moves the center of the map to the specified point.

Description

The CenterAt method positions the supplied x and y map coordinates in the center of the ARMap display area. The extent of the ARMap will change, but the MapScale will remain the same.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
centerAt in interface IARMap
Parameters:
xCoord - The xCoord (in)
yCoord - The yCoord (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#zoomIn(double), com.esri.arcgis.publishercontrols.IARMap#zoomOut(double), com.esri.arcgis.publishercontrols.IARMap#pan(int, double)

setRotation

public void setRotation(double mapRotation)
                 throws IOException,
                        AutomationException
The number of degrees the map display is rotated.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

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

getRotation

public double getRotation()
                   throws IOException,
                          AutomationException
The number of degrees the map display is rotated.

Description

The Rotation property indicates the rotation of the ARMap display, and so the angle data appears inside the ARMap. The angle of the rotation is measured in degrees. Positive numbers rotate the display counter clockwise and negative numbers clockwise.

Remarks

Use the Refresh method to redraw the ARMap display area in order to see the rotated ARMap data.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getRotation in interface IARMap
Returns:
The mapRotation
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryARFeatures

public IARFeatureSet queryARFeatures(IARSearchDef pSearchDef)
                              throws IOException,
                                     AutomationException
Searches the map using a search definition and returns an ARFeatureSet.

Description

Queries the ARMap based upon an attribute or spatial query as defined by the ArcReaderSearchDef. Only ARLayer objects with a Searchable property set to true within the ARMap will be searched.

All ARFeature objects matching the query are instantiated in the ARFeatureSet. If the number of features could be very large, this may not be desirable as it may result in a long delay and consume a large amount of memory. Instead use the SearchARFeatures method. If there are no features matching the query the IARFeatureSet::ARFeatureCount property will return 0.

Remarks

The QueryARFeatures method will return an error if the currently loaded document was not published with permission to QueryFeatures. Use the IARControl::HasDocumentPermission method to determine this.

If there is an error with the query, such as ill-formed SQL, the error returned will contain an error description from the underlying database.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
queryARFeatures in interface IARMap
Parameters:
pSearchDef - A reference to a com.esri.arcgis.controls.IARSearchDef (in)
Returns:
A reference to a com.esri.arcgis.controls.IARFeatureSet
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toMapPoint

public void toMapPoint(int x,
                       int y,
                       double[] xCoord,
                       double[] yCoord)
                throws IOException,
                       AutomationException
Converts a point in device coordinates (typically pixels) to coordinates in map units.

Description

Converts the x and y screen coordinates supplied in pixels to x and y map coordinates. The screen coordinates are relative to the top left of the ARMap display area. To obtain the offset of the display area from the top left of the ArcReaderControl use the IARControl::ViewTop and IARControl::ViewLeft properties. The returned map coordinates will be in MapUnits.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
toMapPoint in interface IARMap
Parameters:
x - The x (in)
y - The y (in)
xCoord - The xCoord (in/out: use single element array)
yCoord - The yCoord (in/out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isCanUndoExtent

public boolean isCanUndoExtent()
                        throws IOException,
                               AutomationException
Indicates if there is a map extent that can be undone.

Description

Whenever the extent of the map changes the previous extent is placed onto an extent stack. It is possible to navigate backwards and forwards through any extents in the extent stack.

CanUndoExtent indicates if there is an ARMap extent that can be undone. Use the property before using the UndoExtent method.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
isCanUndoExtent in interface IARMap
Returns:
The bCanUndo
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#undoExtent(), com.esri.arcgis.publishercontrols.IARMap#redoExtent(), com.esri.arcgis.publishercontrols.IARMap

undoExtent

public void undoExtent()
                throws IOException,
                       AutomationException
Undo to the previous map extent in the stack.

Description

Undo the ARMap extent to the previous extent in the extent stack. Use the CanUndoExtent property to determine whether the extent can be undone.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
undoExtent in interface IARMap
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#redoExtent(), com.esri.arcgis.publishercontrols.IARMap

isCanRedoExtent

public boolean isCanRedoExtent()
                        throws IOException,
                               AutomationException
Indicates if there is a map extent that can be redone.

Description

Whenever the extent of the map changes the previous extent is placed onto an extent stack. It is possible to navigate backwards and forwards through any extents in the extent stack.

CanRedoExtent indicates if there is an ARMap extent that can be redone. Use the property before using the RedoExtent method.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
isCanRedoExtent in interface IARMap
Returns:
The bCanRedo
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#undoExtent(), com.esri.arcgis.publishercontrols.IARMap#redoExtent(), com.esri.arcgis.publishercontrols.IARMap

redoExtent

public void redoExtent()
                throws IOException,
                       AutomationException
Redo the next map extent in the stack.

Description

Redo the ARMap extent to the next extent in the extent stack. Use the CanRedoExtent property to determine whether the extent can be redone.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
redoExtent in interface IARMap
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#undoExtent(), com.esri.arcgis.publishercontrols.IARMap

getInternalObject

public Object getInternalObject()
                         throws IOException,
                                AutomationException
The internal ArcObjects IMap object.

Description

Use the InternalObject property to access the underlying IMap object. This property is always inaccessible.

Remarks

Getting the InternalObject property will return an error if no license is available and if the currently loaded document was not published with permission to access InternalObjects. Use the IARControl::HasDocumentPermission method to determine this.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

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

getBookmarkCount

public int getBookmarkCount()
                     throws IOException,
                            AutomationException
The number of bookmarks in the map's bookmark collection.

Description

The BookmarkCount property returns the number of spatial bookmarks within the ARMap.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getBookmarkCount in interface IARMap
Returns:
The pVal
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#centerAtBookmark(java.lang.Object), com.esri.arcgis.publishercontrols.IARMap#getBookmarkName(int), com.esri.arcgis.publishercontrols.IARMap#zoomToBookmark(java.lang.Object)

getBookmarkName

public String getBookmarkName(int index)
                       throws IOException,
                              AutomationException
The name of the bookmark.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

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

zoomToBookmark

public void zoomToBookmark(Object vBookmarkID)
                    throws IOException,
                           AutomationException
Zooms the map display to the bookmark.

Description

Zooms to the spatial bookmark to make it visible on the display as the new viewing extent, changing the MapScale.

Specify a BookmarkName or a zero-based index to zoom to a spatial bookmark. For example, to zoom to the first spatial bookmark in the collection, pass an index of 0, and to zoom to the last spatial bookmark in the layer collection, pass an index of (BookmarkCount - 1).

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
zoomToBookmark in interface IARMap
Parameters:
vBookmarkID - A Variant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#centerAtBookmark(java.lang.Object), com.esri.arcgis.publishercontrols.IARMap#getBookmarkName(int), com.esri.arcgis.publishercontrols.IARMap#getBookmarkCount()

centerAtBookmark

public void centerAtBookmark(Object vBookmarkID)
                      throws IOException,
                             AutomationException
Centers the map display on the bookmark.

Description

Centers the spatial bookmark on the display to make it visible. The extent of the ARMap will change, but the MapScale will remain the same.

Specify a BookmarkName or a zero-based index to center a spatial bookmark. For example, to center the first spatial bookmark in the collection, pass an index of 0, and to center the last spatial bookmark in the layer collection, pass an index of (BookmarkCount - 1).

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
centerAtBookmark in interface IARMap
Parameters:
vBookmarkID - A Variant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#getBookmarkName(int), com.esri.arcgis.publishercontrols.IARMap#getBookmarkCount(), com.esri.arcgis.publishercontrols.IARMap#zoomToBookmark(java.lang.Object)

zoomToFullExtent

public void zoomToFullExtent()
                      throws IOException,
                             AutomationException
Zoom to the full extent of all data within the map.

Description

Changes the ARMap's viewing extent to show the full extent of all data layers, causing the MapScale property to change. The ZoomToFullExtent method automatically refreshes the ARMap display area.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
zoomToFullExtent in interface IARMap
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.publishercontrols.IARMap#setExtent(double, double, double, double), com.esri.arcgis.publishercontrols.IARMap#getFullExtent(double[], double[], double[], double[]), com.esri.arcgis.publishercontrols.IARMap#getExtent(double[], double[], double[], double[])

getCustomProperty

public Object getCustomProperty()
                         throws IOException,
                                AutomationException
A property to associate data with an object.

Description

Use the CustomProperty to associate any useful data with the ARMap. This is similar to a 'Tag' property, and can be use to store strings, numbers and objects.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
getCustomProperty in interface IARMap
Returns:
A Variant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setCustomProperty

public void setCustomProperty(Object pVal)
                       throws IOException,
                              AutomationException
A property to associate data with an object.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
setCustomProperty in interface IARMap
Parameters:
pVal - A Variant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

searchARFeatures

public IARFeatureCursor searchARFeatures(IARSearchDef pSearchDef)
                                  throws IOException,
                                         AutomationException
Searches the map using a search definition and returns an ARFeatureCursor.

Description

Searches the ARMap based upon an attribute or spatial query as defined by the ArcReaderSearchDef. Only ARLayer objects with a Searchable property set to true within the ARMap will be searched.

Use the ARFeatureCursor to retrieve each ARFeature one at a time. If there are no ARFeature objects matching the query the first IARFeatureCursor::NextARFeature will return nothing.

Remarks

The SearchARFeatures method will return an error if the currently loaded document was not published with permission to QueryFeatures. Use the IARControl::HasDocumentPermission method to determine this.

If there is an error with the query, such as ill-formed SQL, the error returned will contain an error description from the underlying database.

Product Availability

Available with ArcGIS Desktop. Requires Publisher Extension.

Specified by:
searchARFeatures in interface IARMap
Parameters:
pSearchDef - A reference to a com.esri.arcgis.controls.IARSearchDef (in)
Returns:
A reference to a com.esri.arcgis.controls.IARFeatureCursor
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.