com.esri.arcgis.carto
Class PageLayout

java.lang.Object
  extended by com.esri.arcgis.carto.PageLayout
All Implemented Interfaces:
IActiveView, IGraphicsContainer, IGraphicsContainerSelect, IGraphicSnapEnvironment, IMxdContents, IPageEvents, IPageLayout, IPageLayout2, IPageLayout3, IPageLayoutExtensions, ISelectionEvents, IViewManager, IViewRefresh, IConnectionPointContainer, IDisplayAdmin, ITransformEvents, com.esri.arcgis.interop.RemoteObjRef, IPersist, IPersistStream, Externalizable, Serializable, EventListener

public class PageLayout
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, IPageLayout, IPageLayout2, IPageLayout3, IActiveView, IViewManager, IViewRefresh, IGraphicsContainer, IGraphicsContainerSelect, IGraphicSnapEnvironment, IConnectionPointContainer, IPersistStream, IPersist, IPageEvents, ISelectionEvents, ITransformEvents, IDisplayAdmin, IMxdContents, IPageLayoutExtensions, Externalizable

Page Layout class contains maps and map surrounds.

Remarks

The PageLayout manages the layout of a hard copy output page. The PageLayout has a collection of elements organized as follows:

Printer - A reference to te application's printer. Managaes paper size, margins, and other settings.
Page - Manages the visual (on screen) representation of the printer page.
Elements - A list of map elements that are drawn on the page.
Graphics - A list of graphic elements that are drawn on the page.

ArcMap's layout view corresponds to the PageLayout object, and like all views, the PageLayout implements the IActiveView interface allowing it to take control of the main application window.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

See Also:
Serialized Form

Constructor Summary
PageLayout()
          Constructs a PageLayout using ArcGIS Engine.
PageLayout(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
PageLayout thePageLayout = (PageLayout) obj;
 
Method Summary
 void activate(int hWnd)
          Gives this view control of the specified window.
 void addElement(IElement element, int zorder)
          Add a new graphic element to the layer.
 void addElements(IElementCollection elements, int zorder)
          Add new graphic elements to the layer.
 void addExtension(Object ext)
          Adds a new extension.
 void addIActiveViewEventsListener(IActiveViewEvents theListener)
          addIActiveViewEventsListener.
 void addSnapAgent(IGraphicSnap snapAgent)
          Add a new snap agent to the environment.
 void animationRefresh(int phase, Object data, IEnvelope envelope)
          Use to quickly redraw a phase that has it's own cache, i.e., a tracking layer.
 void animationRefreshShape(int phase, Object data, IGeometry geometry, double symbolSizePoints)
          Use to quickly redraw a phase that has it's own cache, i.e., a tracking layer.
 void boundsUpdated(ITransformEventsBoundsUpdatedEvent theEvent)
          Notifies clients when the bounds is updated.
 void bringForward(IEnumElement elements)
          Move the specified elements one step closer to the top of the stack of elements.
 void bringToFront(IEnumElement elements)
          Make the specified elements draw in front of all other elements.
 void clear()
          Empties the view contents.
 void clearContent()
          Clears the elements without dismantling them.
 void clearSnapAgents()
          Remove all snap agents.
 void contentsChanged()
          Called by clients when view objects are modified.
 void deactivate()
          Another view takes over the associated window.
 void deleteAllElements()
          Delete all the elements.
 void deleteElement(IElement element)
          Delete the given element.
 void deleteSnapAgent(IGraphicSnap snapAgent)
          Remove specified snap agent from the environment.
 void deviceFrameUpdated(ITransformEventsDeviceFrameUpdatedEvent theEvent)
          Notifies clients when the device frame is updated.
 void draw(int hDC, ITrackCancel trackCancel)
          Draws the view to the specified device context.
 boolean elementSelected(IElement element)
          Indicates if the element is selected.
 void enumConnectionPoints(IEnumConnectionPoints[] ppEnum)
          enumConnectionPoints
 boolean equals(Object o)
          Compare this object with another
 void findConnectionPoint(GUID riid, IConnectionPoint[] ppCP)
          findConnectionPoint
 IFrameElement findFrame(Object frameObject)
          Find the frame that contains the specified object.
 void focusNextMapFrame()
          Focus the next map.
 void focusPreviousMapFrame()
          Focus the previous map.
 IActiveView getActiveView()
          The Map object.
 void getClassID(GUID[] pClassID)
          getClassID
static String getClsid()
          getClsid.
 Object getContentProvider()
          The object that is currently managing the content of the layout.
 void getContextMenu(double x, double y, IUID[] clsidMenu)
          Called when a context menu should be displayed at the given xy location.
 IElement getDominantElement()
          Dominant element.
 Object getElementOrder(IEnumElement elements)
          Private order object.
 ISelection getElementSelection()
          Object to use for element selection.
 int getElementSelectionCount()
          The number of selected elements.
 tagRECT getExportFrame()
          The device rectangle to export.
 Object getExtension(int index)
          The extension at the specified index.
 int getExtensionCount()
          Number of extensions.
 IEnvelope getExtent()
          The visible extent rectangle.
 IExtentStack getExtentStack()
          The extent stack.
 IMap getFocusMap()
          The map that tools and controls act on.
 IEnvelope getFullExtent()
          The full extent rectangle.
 IGraphicsContainer getGraphicsContainer()
          The active graphics container.
 ISnapGuides getHorizontalSnapGuides()
          The horizontal snapping guides.
 IMap getMap()
          The Map object.
 int getOutputBandSize()
          Size allocated for each band when banding output.
 IPage getPage()
          The page.
 IPageLayout getPageLayout()
          The PageLayout object.
 IPrinter getPrinter()
          The associated printer.
 IRulerSettings getRulerSettings()
          The ruler settings.
 short getScreenCacheID(int phase, Object data)
          The screen cache ID that is used to draw the specified phase.
 IScreenDisplay getScreenDisplay()
          The screen display used by the view.
 IEnumElement getSelectedElements()
          The selected elements.
 ISelection getSelection()
          The selection.
 IEnvelope getSelectionBounds(IDisplay display)
          The bounds of the selection.
 void getSizeMax(_ULARGE_INTEGER[] pcbSize)
          getSizeMax
 IGraphicSnap getSnapAgent(int index)
          The snap agent at the specified index.
 int getSnapAgentCount()
          The number of snap agents.
 IArray getSnapAgentOrder()
          An array of IDs indicating how agents should be ordered.
 ISnapGrid getSnapGrid()
          The snapping grid.
 double getSnapTolerance()
          The snap tolerance in page units.
 String getTipText(double x, double y)
          The tip text to display at the given location.
 int getTopFilterIndex()
          Phase index that supplements TopFilterPhase.
 int getTopFilterPhase()
          The highest phase in the drawing order that uses a display filter.
 ISnapGuides getVerticalSnapGuides()
          The vertical snapping guides.
 double getZoomPercent()
          The current zoom percent.
 int hashCode()
          the hashcode for this object
 IMap hitTestMap(IPoint location)
          Returns any maps present in the view at the given location.
 boolean isActive()
          Indicates if view is active or not.
 boolean isAlignToMargins()
          Indicates if graphics will be aligned to the margins or to each other.
 boolean isConserveMemory()
          Indicates whether to be conservative when allocating resources.
 boolean isDelayBackgroundDraw()
          Indicates if the background should draw immediately.
 boolean isDelayEvents()
          Indicates if the layout stops firing events until the flag is set to false.
 void isDirty()
          isDirty
 boolean isDrawing()
          Indicates whether the view is currently drawing or not.
 boolean isExternalDrawing(int phase)
          Indicates if external clients are drawing in response to the specified phase.
 boolean isMapActivated()
          Indicates if the focus map is activated.
 boolean isProgressiveDrawing()
          Indicates whether the view should progressively update the window during drawing.
 boolean isShowRulers()
          Indicates if rulers are visible.
 boolean isShowScrollBars()
          Indicates if scrollbars are visible.
 boolean isShowSelection()
          Indicates if selection is visible.
 boolean isUsesFilter()
          Indicates if the current object draws using a filter.
 boolean isUsesPageCoordinates()
          Indicates whether view uses page coordinates.
 boolean isVerboseEvents()
          Indicates whether to expand or limit the number of events that are fired.
 void load(IStream pstm)
          load
 IEnumElement locateElements(IPoint point, double tolerance)
          Returns the elements at the given coordinate.
 IEnumElement locateElementsByEnvelope(IEnvelope envelope)
          Returns the elements inside the given envelope.
 void moveElementFromGroup(IGroupElement group, IElement element, int zorder)
          Move the element from the group to the container.
 void moveElementToGroup(IElement element, IGroupElement group)
          Move the element from the container to the group.
 IElement next()
          Returns the next graphic in the container.
 void onMessage(int msg, int wParam, int lParam)
          Call from your application's message loop to enable automatic resizing and keyboard accelerators.
 void output(int hDC, int dpi, tagRECT pixelBounds, IEnvelope visibleBounds, ITrackCancel trackCancel)
          Renders the view to the specified DC.
 void pageColorChanged(IPageEventsPageColorChangedEvent theEvent)
          Fired when the page color changes.
 void pageMarginsChanged(IPageEventsPageMarginsChangedEvent theEvent)
          Fired when the page margins change.
 void pageSizeChanged(IPageEventsPageSizeChangedEvent theEvent)
          Fired when the page size changes.
 void pageUnitsChanged(IPageEventsPageUnitsChangedEvent theEvent)
          Fired when the units used by the page changes.
 void partialRefresh(int phase, Object data, IEnvelope envelope)
          Draws the specified view phase.
 void partialRefreshShape(int phase, Object data, IGeometry geometry, double symbolSizePoints)
          Refreshes the specified shape on the specified view phase.
 void printerChanged(IPrinter printer)
          Called by application when printer changes.
 void putElementOrder(Object order)
          Private order object.
 void readExternal(ObjectInput in)
           
 void refresh()
          Causes the entire view to draw.
 void refreshCaches()
          Reallocate the display caches.
 void refreshItem(Object data)
          Use to redraw a specific item and the content above it.
 void removeExtension(int index)
          Removes the specified extension.
 void removeIActiveViewEventsListener(IActiveViewEvents theListener)
          removeIActiveViewEventsListener.
 void replaceMaps(IMaps maps)
          Replace the maps in the data frames with the specified maps.
 void reset()
          Reset internal cursor so that Next returns the first element.
 void resolutionUpdated(ITransformEventsResolutionUpdatedEvent theEvent)
          Notifies clients when the resolution is updated.
 void rotationUpdated(ITransformEventsRotationUpdatedEvent theEvent)
          Notifies clients when the rotation angle is updated.
 void save(IStream pstm, int fClearDirty)
          save
 void selectAllElements()
          Selects all elements.
 IElement selectedElement(int index)
          Returns the nth selected element.
 void selectElement(IElement element)
          Selects the specified element.
 void selectElements(IEnumElement elements)
          Selects the specified elements.
 void selectionChanged(ISelectionEventsSelectionChangedEvent theEvent)
          Call this function to fire the selection changed event.
 ISelectionTracker selectionTracker(int index)
          Returns the tracker for the nth selected element.
 void sendBackward(IEnumElement elements)
          Move the specified elements one step closer to the bottom of the stack of elements.
 void sendToBack(IEnumElement elements)
          Make the specified elements draw behind all other elements.
 void setAlignToMargins(boolean alignToMargins)
          Indicates if graphics will be aligned to the margins or to each other.
 void setConserveMemory(boolean flag)
          Indicates whether to be conservative when allocating resources.
 void setContentProviderByRef(Object provider)
          The object that is currently managing the content of the layout.
 void setDelayBackgroundDraw(boolean flag)
          Indicates if the background should draw immediately.
 void setDelayEvents(boolean delayEvents)
          Indicates if the layout stops firing events until the flag is set to false.
 void setDominantElementByRef(IElement dominantItem)
          Dominant element.
 void setElementSelectionByRef(ISelection selectionObject)
          Object to use for element selection.
 void setExtent(IEnvelope extent)
          The visible extent rectangle.
 void setExternalDrawing(int phase, boolean externalDrawing)
          Indicates if external clients are drawing in response to the specified phase.
 void setFocusMapByRef(IMap activeMap)
          The map that tools and controls act on.
 void setFullExtent(IEnvelope extent)
          The full extent rectangle.
 void setIsMapActivated(boolean isMapActivated)
          Indicates if the focus map is activated.
 void setOutputBandSize(int kilobytes)
          Size allocated for each band when banding output.
 void setProgressiveDrawing(boolean flag)
          Indicates whether the view should progressively update the window during drawing.
 void setSelectionByRef(ISelection selection)
          The selection.
 void setShowRulers(boolean showRulers)
          Indicates if rulers are visible.
 void setShowScrollBars(boolean showScrollBars)
          Indicates if scrollbars are visible.
 void setShowSelection(boolean showRulers)
          Indicates if selection is visible.
 void setSnapAgentOrder(IArray guids)
          An array of IDs indicating how agents should be ordered.
 void setSnapTolerance(double tol)
          The snap tolerance in page units.
 void setTopFilterIndex(int phaseIndex)
          Phase index that supplements TopFilterPhase.
 void setTopFilterPhase(int phase)
          The highest phase in the drawing order that uses a display filter.
 void setVerboseEvents(boolean verboseEvents)
          Indicates whether to expand or limit the number of events that are fired.
 void snapShape(IGeometry shape)
          Snap the shape using the agents in the environment.
 void unitsUpdated(ITransformEventsUnitsUpdatedEvent theEvent)
          Notifies clients when the units are updated.
 void unselectAllElements()
          Unselects all elements.
 void unselectElement(IElement element)
          Unselects the specified element.
 void unselectElements(IEnumElement elements)
          Unselects the specified elements.
 void updateElement(IElement element)
          The graphic element's properties have changed.
 void visibleBoundsUpdated(ITransformEventsVisibleBoundsUpdatedEvent theEvent)
          Notifies clients when the visible bounds is updated.
 void writeExternal(ObjectOutput out)
           
 void zoomToPercent(int percent)
          Magnify the page by a certain percentage.
 void zoomToWhole()
          Fit the whole page in the window.
 void zoomToWidth()
          Fit the width of the page to the screen.
 
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

PageLayout

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

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

PageLayout

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

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

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

addIActiveViewEventsListener

public void addIActiveViewEventsListener(IActiveViewEvents theListener)
                                  throws IOException
addIActiveViewEventsListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.carto.IActiveViewEvents interface.
Throws:
IOException - If there are communications problems.

removeIActiveViewEventsListener

public void removeIActiveViewEventsListener(IActiveViewEvents theListener)
                                     throws IOException
removeIActiveViewEventsListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.carto.IActiveViewEvents interface.
Throws:
IOException - If there are communications problems.

getPage

public IPage getPage()
              throws IOException,
                     AutomationException
The page.

Remarks

Returns an IPage reference on the Page object. The PageLayout object has a Page object which manages the visual (on screen) representation of the printer page.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getPage in interface IPageLayout
Specified by:
getPage in interface IPageLayout2
Specified by:
getPage in interface IPageLayout3
Returns:
A reference to a com.esri.arcgis.carto.IPage
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IPage, Page

getRulerSettings

public IRulerSettings getRulerSettings()
                                throws IOException,
                                       AutomationException
The ruler settings.

Remarks

You can use rulers, guides, and grids in layout view to align elements on the page. Rulers show the size of the page and elements on the final printed map.

This property returns an IRulerSettings reference on the RulerSettings object. The PageLayout object has a RulerSettings object which manages ruler settings. IRulerSettings only has one property, SmallestDivision. This property controls the size of the smallest ruler division in page units. For example, if the page size is 8.5 by 11 inches, and the SmallestDivision is set to 2, the rulers, seen in layout view, will read off every 2 inches; if the property is set to .1, the rulers will read of every 1/10 of an inch.

Example:


<pre>

MapControl pMapControl = new MapControl();
IRulerSettings pRulerSettings;
pRulerSettings = pMapControl.getPageLayout().getRulerSettings();
pRulerSettings.setSmallestDivision(2);
pMapControl.getActiveView().refresh();

</pre>
</font>

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getRulerSettings in interface IPageLayout
Specified by:
getRulerSettings in interface IPageLayout2
Specified by:
getRulerSettings in interface IPageLayout3
Returns:
A reference to a com.esri.arcgis.carto.IRulerSettings
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSnapGrid

public ISnapGrid getSnapGrid()
                      throws IOException,
                             AutomationException
The snapping grid.

Remarks

You can use rulers, guides, and grids in layout view to align elements on the page. A grid is a grid of reference points on the layout that you can use to position elements. The grid may be used as a visual indicator of size and position. The grid can also be used to snap elements into position.

This property returns an ISnapGrid reference on the SnapGrid object.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getSnapGrid in interface IPageLayout
Specified by:
getSnapGrid in interface IPageLayout2
Specified by:
getSnapGrid in interface IPageLayout3
Returns:
A reference to a com.esri.arcgis.carto.ISnapGrid
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getHorizontalSnapGuides

public ISnapGuides getHorizontalSnapGuides()
                                    throws IOException,
                                           AutomationException
The horizontal snapping guides.

Remarks

You can use rulers, guides, and grids in layout view to align elements on the page. Guides are straight lines that you can use to align elements on the page.

The PageLayout object has two SnapGuides objects, one for managing horizontal guides and one for managing vertical guides. This property returns an ISnapGuides reference on the horizontal SnapGuides object.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getHorizontalSnapGuides in interface IPageLayout
Specified by:
getHorizontalSnapGuides in interface IPageLayout2
Specified by:
getHorizontalSnapGuides in interface IPageLayout3
Returns:
A reference to a com.esri.arcgis.carto.ISnapGuides
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getVerticalSnapGuides

public ISnapGuides getVerticalSnapGuides()
                                  throws IOException,
                                         AutomationException
The vertical snapping guides.

Remarks

You can use rulers, guides, and grids in layout view to align elements on the page. Guides are straight lines that you can use to align elements on the page.

The PageLayout object has two SnapGuides objects, one for managing horizontal guides and one for managing vertical guides. This property returns an ISnapGuides reference on the vertical SnapGuides object.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getVerticalSnapGuides in interface IPageLayout
Specified by:
getVerticalSnapGuides in interface IPageLayout2
Specified by:
getVerticalSnapGuides in interface IPageLayout3
Returns:
A reference to a com.esri.arcgis.carto.ISnapGuides
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getZoomPercent

public double getZoomPercent()
                      throws IOException,
                             AutomationException
The current zoom percent. 100 means 1:1. 200 means twice normal size, etc.

Remarks

This property reports the current zoom factor. Use ZoomToPercent, ZoomToWhole, or ZoomToWidth to change the zoom factor.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getZoomPercent in interface IPageLayout
Specified by:
getZoomPercent in interface IPageLayout2
Specified by:
getZoomPercent in interface IPageLayout3
Returns:
The percent
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IPageLayout.zoomToWhole(), IPageLayout.zoomToWidth(), IPageLayout.zoomToPercent(int), IPageLayout.getZoomPercent()

setAlignToMargins

public void setAlignToMargins(boolean alignToMargins)
                       throws IOException,
                              AutomationException
Indicates if graphics will be aligned to the margins or to each other.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setAlignToMargins in interface IPageLayout
Specified by:
setAlignToMargins in interface IPageLayout2
Specified by:
setAlignToMargins in interface IPageLayout3
Parameters:
alignToMargins - The alignToMargins (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isAlignToMargins

public boolean isAlignToMargins()
                         throws IOException,
                                AutomationException
Indicates if graphics will be aligned to the margins or to each other.

Remarks

Align tools can either align select elements with each other or with the margins of the map. When this property is set to TRUE, the align tools will snap the selected elements to the margins of the map. When this property is set to FALSE, the align tools align the selected elements with each other.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isAlignToMargins in interface IPageLayout
Specified by:
isAlignToMargins in interface IPageLayout2
Specified by:
isAlignToMargins in interface IPageLayout3
Returns:
The alignToMargins
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

zoomToWidth

public void zoomToWidth()
                 throws IOException,
                        AutomationException
Fit the width of the page to the screen.

Remarks

Use the ZoomPercent property to check the zoom factor.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
zoomToWidth in interface IPageLayout
Specified by:
zoomToWidth in interface IPageLayout2
Specified by:
zoomToWidth in interface IPageLayout3
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IPageLayout.zoomToWhole(), IPageLayout.zoomToWidth(), IPageLayout.zoomToPercent(int), IPageLayout.getZoomPercent()

zoomToWhole

public void zoomToWhole()
                 throws IOException,
                        AutomationException
Fit the whole page in the window.

Remarks

Use the ZoomPercent property to check the zoom factor.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
zoomToWhole in interface IPageLayout
Specified by:
zoomToWhole in interface IPageLayout2
Specified by:
zoomToWhole in interface IPageLayout3
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IPageLayout.zoomToWhole(), IPageLayout.zoomToWidth(), IPageLayout.zoomToPercent(int), IPageLayout.getZoomPercent()

zoomToPercent

public void zoomToPercent(int percent)
                   throws IOException,
                          AutomationException
Magnify the page by a certain percentage. 100 means actual size. 200 means twice normal size, etc.

Remarks

Use the ZoomPercent property to check the zoom factor.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
zoomToPercent in interface IPageLayout
Specified by:
zoomToPercent in interface IPageLayout2
Specified by:
zoomToPercent in interface IPageLayout3
Parameters:
percent - The percent (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IPageLayout.zoomToWhole(), IPageLayout.zoomToWidth(), IPageLayout.zoomToPercent(int), IPageLayout.getZoomPercent()

focusNextMapFrame

public void focusNextMapFrame()
                       throws IOException,
                              AutomationException
Focus the next map.

Remarks

Changes the focus map to the next MapFrame in the collection. This method fires the IActiveViewEvents::FocusMapChanged event.

In ArcMap's layout view, the tab key switches the focus map to the next map. Shift-tab changes the focus map to the previous map.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
focusNextMapFrame in interface IPageLayout
Specified by:
focusNextMapFrame in interface IPageLayout2
Specified by:
focusNextMapFrame in interface IPageLayout3
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

focusPreviousMapFrame

public void focusPreviousMapFrame()
                           throws IOException,
                                  AutomationException
Focus the previous map.

Remarks

Changes the focus map to the previous MapFrame in the collection. This method fires the IActiveViewEvents::FocusMapChanged event.

In ArcMap's layout view, the tab key switches the focus map to the next map. Shift-tab changes the focus map to the previous map.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
focusPreviousMapFrame in interface IPageLayout
Specified by:
focusPreviousMapFrame in interface IPageLayout2
Specified by:
focusPreviousMapFrame in interface IPageLayout3
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

replaceMaps

public void replaceMaps(IMaps maps)
                 throws IOException,
                        AutomationException
Replace the maps in the data frames with the specified maps. If there are more maps than frames, new frames are created. If there are fewer frames than maps, extra frames are cleared.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
replaceMaps in interface IPageLayout
Specified by:
replaceMaps in interface IPageLayout2
Specified by:
replaceMaps in interface IPageLayout3
Parameters:
maps - A reference to a com.esri.arcgis.carto.IMaps (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setContentProviderByRef

public void setContentProviderByRef(Object provider)
                             throws IOException,
                                    AutomationException
The object that is currently managing the content of the layout.

Product Availability

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

Specified by:
setContentProviderByRef in interface IPageLayout2
Specified by:
setContentProviderByRef in interface IPageLayout3
Parameters:
provider - A reference to another Object (IUnknown) (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getContentProvider

public Object getContentProvider()
                          throws IOException,
                                 AutomationException
The object that is currently managing the content of the layout.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

clearContent

public void clearContent()
                  throws IOException,
                         AutomationException
Clears the elements without dismantling them.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getPrinter

public IPrinter getPrinter()
                    throws IOException,
                           AutomationException
The associated printer.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getPrinter in interface IPageLayout2
Specified by:
getPrinter in interface IPageLayout3
Returns:
A reference to a com.esri.arcgis.output.IPrinter
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isDelayEvents

public boolean isDelayEvents()
                      throws IOException,
                             AutomationException
Indicates if the layout stops firing events until the flag is set to false.

Product Availability

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

Specified by:
isDelayEvents in interface IPageLayout3
Returns:
The delayEvents
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setDelayEvents

public void setDelayEvents(boolean delayEvents)
                    throws IOException,
                           AutomationException
Indicates if the layout stops firing events until the flag is set to false.

Product Availability

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

Specified by:
setDelayEvents in interface IPageLayout3
Parameters:
delayEvents - The delayEvents (in)
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 rectangle.

Remarks

The full extent of the view. In ArcMap's data view, the full extent is the full extent of all layers and it is automatically calculated whenever the spatial reference changes and when layers are added or removed with AddLayer, AddLayers, or DeleteLayer. In layout view, the full extent is the page size expanded some and it is automatically set whenever the page size changes.

This property is a shortcut to the bounds of the ActiveView's ScreenDisplay (accessed via IDisplayTransformation::Bounds) .

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getFullExtent in interface IActiveView
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.
See Also:
IDisplayTransformation.getBounds(), IDisplayTransformation, IActiveView.getFullExtent()

setFullExtent

public void setFullExtent(IEnvelope extent)
                   throws IOException,
                          AutomationException
The full extent rectangle.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setFullExtent in interface IActiveView
Parameters:
extent - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getExtent

public IEnvelope getExtent()
                    throws IOException,
                           AutomationException
The visible extent rectangle.

Remarks

The Extent property holds the visible area of the view. The Extent is automatically captured whenever the view's transformation changes. For example, when the active view is a Map, the Extent is modified whenever the spatial reference changes. Also, the Extent is set the first time a layer is added to a Map. In layout view, the Extent is initially set to the page size. In both layout view and data view, zooming in our out changes the Extent.

The Extent is always adjusted to fit the device frame and it is persisted in the map document.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getExtent in interface IActiveView
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.
See Also:
IDisplayTransformation.getVisibleBounds(), ITin.getExtent(), IActiveView.getExtent(), IFeatureClassManage.updateExtent(), IFeatureClassManage, IDisplayTransformation.getFittedBounds()

setExtent

public void setExtent(IEnvelope extent)
               throws IOException,
                      AutomationException
The visible extent rectangle.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setExtent in interface IActiveView
Parameters:
extent - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getScreenDisplay

public IScreenDisplay getScreenDisplay()
                                throws IOException,
                                       AutomationException
The screen display used by the view.

Remarks

Each view has a ScreenDisplay object which controls drawing in the application's window. Use this property to get a reference to the ScreenDisplay object associated with the view you are currently working with. For example, to draw a polygon in data view, you must get an IActiveView reference on the focus Map object and then get a reference to its ScreenDisplay object via this property. If you are in data view and you mistakenly get an IActiveView reference on the PageLayout object, you will not see the polygon as you are drawing in the wrong view.

Each ScreenDisplay object has a DisplayTransformation object which is accessible via IDisplay::DisplayTransformation (ScreenDisplay inherits from Display ). Each DisplayTransformation related to a Map, holds onto the map's spatial reference (IDisplayTransformation::SpatialReference ) and has useful methods for converting between device units and map units. The PageLayout's DisplayTransformation does not have a spatial reference, the property returns nothing, and in this case its members map between device units and page units.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getScreenDisplay in interface IActiveView
Returns:
A reference to a com.esri.arcgis.display.IScreenDisplay
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getGraphicsContainer

public IGraphicsContainer getGraphicsContainer()
                                        throws IOException,
                                               AutomationException
The active graphics container.

Remarks

Both the Map and PageLayout objects are graphics containers - both implement the IGraphicsContainer interface.

The Map has a Basics Graphics Layer and this property returns a reference to that object (see CompositeGraphicsLayer and IMap::BasicGraphicsLayer). When working with a Map object, you can also perform a query interface from any of the interfaces the Map implements, IMap for example, to IGraphicsContainer. The QI also takes you to the CompositeGraphicsLayer object. These are both possible because the Map aggregates the Basic Graphics Layer.

The PageLayout object works differently. The PageLayout does not have a Basics Graphics Layer; instead, the PageLayout object is its own graphics container having its own implementation of IGraphicsContainer. A QI from IPageLayout to IGraphicsContainer connects you with the graphics container associated strictly with the PageLayout. However, this property, IActiveView::GraphicsContainer, on the PageLayout object has two possible outcomes. If a Map is activated (IActiveView::IsMapActivated), the property will return a reference to the focus Map's active graphics layer (IMap::ActiveGraphicsLayer ). If no Map is activated, the property will return a reference to the PageLayout's graphics container - the same as the QI case.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getFocusMap

public IMap getFocusMap()
                 throws IOException,
                        AutomationException
The map that tools and controls act on.

Remarks

A user's map may comprise one or more Map objects. Each Map object typically holds layers of data as well as several MapSurround objects such as a Legend. This property returns an IMap reference to the Map object that currently has focus. In ArcMap, the focus map is the one visible in data view and the one selected in layout view.

Changing the focus map fires the IActiveViewEvents::FocusMapChanged event. In ArcMap, the focus map is automatically set to any new Map added.

IMxDocument::FocusMap is a read-only short cut to this property.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getFocusMap in interface IActiveView
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.
See Also:
com.esri.arcgis.carto.IMxDocument

setFocusMapByRef

public void setFocusMapByRef(IMap activeMap)
                      throws IOException,
                             AutomationException
The map that tools and controls act on.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setFocusMapByRef in interface IActiveView
Parameters:
activeMap - 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.

isMapActivated

public boolean isMapActivated()
                       throws IOException,
                              AutomationException
Indicates if the focus map is activated.

Remarks

In ArcMap's layout view, when the focus map is activated by double-clicking on it, new graphic elements are added to the Map's active graphics layer. When the focus map is not activated, the default, graphic elements are added to the PageLayout object. Both the Map and PageLayout objects are graphics containers, setting this property to TRUE diverts graphics from the PageLayout to the focus Map.

A Map can be activated in both layout and data views.

When this property is set to TRUE, IActiveView::PartialRefresh is called for the esriViewGraphicSelection draw phase.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isMapActivated in interface IActiveView
Returns:
The isMapActivated
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
com.esri.arcgis.carto.IMxDocument

setIsMapActivated

public void setIsMapActivated(boolean isMapActivated)
                       throws IOException,
                              AutomationException
Indicates if the focus map is activated.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getSelection

public ISelection getSelection()
                        throws IOException,
                               AutomationException
The selection.

Remarks

ArcMap has two different selection types, a feature selection and an element selection. Two different objects represent these selections and both implement the ISelection interface. The feature selection object additionally implements IEnumFeature and the element selection object IEnumElement. The ISelection interface is used for clipboard type operations and the IEnum interfaces are used to loop through the items in the collection.

Each active view object, the PageLayout and all Maps, have their own selection objects. Actually, the PageLayout only has an element selection but each Map has a unique feature and element selection. When working with selections make sure you have the correct active view object.

For a Map, only one of the selections can be active at a time. As mentioned above, this interface provides an ISelection reference to either an element or feature selection depending on which one is currently active. To simplify the matter, IMap has a FeatureSelection property which always returns an ISelection on the feature selection, from which you can obtain an IEnumFeature reference. Just make sure you have the correct Map, usually the FocusMap. To get a Map's element selection, use IViewManager::ElementSelection.

Note: The features returned as part of IEnumFeature are in the spatial reference of the map, so they have the coordinate system and the resolution (1/precision) of the map.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getSelection in interface IActiveView
Returns:
A reference to a com.esri.arcgis.carto.ISelection
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IActiveView.getSelection(), IGraphicsContainerSelect, IMap.getFeatureSelection(), IEnumElement

setSelectionByRef

public void setSelectionByRef(ISelection selection)
                       throws IOException,
                              AutomationException
The selection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getTipText

public String getTipText(double x,
                         double y)
                  throws IOException,
                         AutomationException
The tip text to display at the given location.

Product Availability

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

Specified by:
getTipText in interface IActiveView
Parameters:
x - The x (in)
y - The y (in)
Returns:
The tipText
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getExportFrame

public tagRECT getExportFrame()
                       throws IOException,
                              AutomationException
The device rectangle to export.

Remarks

Returns the area of the view to be exported.

For Maps, this is always the area corresponding to the constrained bounds (IDisplayTransformation::ContstrainedBounds), i.e., the visible bounds intersected with the full bounds. The coordinates are automatically converted, using IDisplayTransformation::TransformRect, from world units to device units.

For PageLayout, this is always the height and width of the page in device units (pixels) when the layout is zoomed to 100%. Because these values are independent of the layout's current zoom level and always correspond to the page instead of the full client area of the application, they are ideal for use when exporting a map to a graphics file. Assign the values of the ExportFrame property to the Export object's PixelBounds property.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getExportFrame in interface IActiveView
Returns:
A Structure: com.esri.arcgis.display.tagRECT
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isShowScrollBars

public boolean isShowScrollBars()
                         throws IOException,
                                AutomationException
Indicates if scrollbars are visible.

Remarks

IActiveView::ShowScrollBars is a short cut to IScreenDisplay::UseScrollBars. Changes to this property are not reflected until the active view changes. For example, when in layout view in ArcMap, programmatically changing the PageLayout to not show its scrollbar will have no effect until the next time the active view is set to the PageLayout - calling IActiveView::Refresh has no effect.

ArcMap uses this property to hide Map's scroll bars when in layout view. Programmatically trying to display a Map's scroll bar in layout view will have no effect, for Maps this setting is only honored in data view and again it requires an active view change before the setting is reflected in the applications window.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isShowScrollBars in interface IActiveView
Returns:
The showScrollBars
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setShowScrollBars

public void setShowScrollBars(boolean showScrollBars)
                       throws IOException,
                              AutomationException
Indicates if scrollbars are visible.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

isShowRulers

public boolean isShowRulers()
                     throws IOException,
                            AutomationException
Indicates if rulers are visible.

Remarks

This property is a boolean flag that applications use to determine whether or not to draw rulers.

This property cannot be set for Maps, they always have rulers turned off.

The PageLayout is the only active view with rulers; an active view change is required before the setting is reflected in the applications window.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isShowRulers in interface IActiveView
Returns:
The showRulers
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setShowRulers

public void setShowRulers(boolean showRulers)
                   throws IOException,
                          AutomationException
Indicates if rulers are visible.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

isShowSelection

public boolean isShowSelection()
                        throws IOException,
                               AutomationException
Indicates if selection is visible.

Description

This property is primarily used to hide a Map's element selection in layout view unless a Map has been activated.

When in layout view, the PageLayout always has its ShowSelection set to true, setting it to false has no effect. Similarly, when in data view, the focus Map always has its ShowSelection set to true and this cannot be overridden.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isShowSelection in interface IActiveView
Returns:
The showRulers
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setShowSelection

public void setShowSelection(boolean showRulers)
                      throws IOException,
                             AutomationException
Indicates if selection is visible.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getExtentStack

public IExtentStack getExtentStack()
                            throws IOException,
                                   AutomationException
The extent stack.

Remarks

Returns a reference to the active view's extent stack. Each active view has an extent stack which remembers previous extents so that users can 'go back' and then 'go forward' to previous extents.

Example:


Map map = new Map();
IExtentStack pExtentStack = map.getActiveView().getExtentStack();
if(pExtentStack.canUndo()){
pExtentStack.undo();
}            

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getScreenCacheID

public short getScreenCacheID(int phase,
                              Object data)
                       throws IOException,
                              AutomationException
The screen cache ID that is used to draw the specified phase.

Product Availability

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

Specified by:
getScreenCacheID in interface IActiveView
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
data - A reference to another Object (IUnknown) (in)
Returns:
The cacheID
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

hitTestMap

public IMap hitTestMap(IPoint location)
                throws IOException,
                       AutomationException
Returns any maps present in the view at the given location. Return value may be zero if there are no maps or the coordinate is not over a map.

Remarks

Use this method on a PageLayout to find the nearest Map based on a point location. For example, when ArcMap's identify tool is used in Layout view, the tool first finds the Map clicked on before it searches for features in the Map.

When using this method on a PageLayout, for the Location parameter, set up the Point in page coordinates. To convert from device coordinates to page coordinates:

  1. Get the ScreenDisplay from the PageLayout using IActiveView::ScreenDisplay.
  2. Get the DisplayTransformation from the ScreenDisplay using IScreenDisplay::DisplayTransformation.
  3. Convert device coordinates (for example from a mouse move) to page coordinates using IDisplayTransformation::ToMapPoint.

Use this method on a Map to obtain a reference to it through IMap.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
hitTestMap in interface IActiveView
Parameters:
location - A reference to a com.esri.arcgis.geometry.IPoint (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.

isActive

public boolean isActive()
                 throws IOException,
                        AutomationException
Indicates if view is active or not.

Remarks

In layout view, all of the Maps and the PageLayout are active. In data view, only the focus map is active.

The PageLayout object uses this property when adding Elements; if the PageLayout is active, new elements are activated (IElement::Activate).

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

activate

public void activate(int hWnd)
              throws IOException,
                     AutomationException
Gives this view control of the specified window.

Remarks

Called to establish the current object as the active view. For example, view commands deactivate (IActiveView::Deactivate) the current view (IMxDocument::ActiveView) before calling Activate on their own associated view.

When working with the IActiveView interface on a MapDocument object, you should always first call IActiveView::Activate() in order to properly initialize the display of the PageLayout or Map object. The MxDocument and MapServer objects and the MapControl and PageLayoutControl all initialize display objects automatically after opening an MXD, but MapDocument does not do this, so you should call Activate() before working with any other members of IActiveView. If your application has a user interface, you should call Activate() with the hWnd of the application's client area. If your application runs in the background and has no windows, you can always get a valid hWnd from the GDI GetDesktopWindow() function, part of the Win32 API.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
activate in interface IActiveView
Parameters:
hWnd - The hWnd (A COM typedef) (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

deactivate

public void deactivate()
                throws IOException,
                       AutomationException
Another view takes over the associated window.

Remarks

Called to deactivate the current active view. For example, view commands deactivate (IActiveView::Deactivate) the current view (IMxDocument::ActiveView) before calling Activate on their own associated view.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

draw

public void draw(int hDC,
                 ITrackCancel trackCancel)
          throws IOException,
                 AutomationException
Draws the view to the specified device context.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
draw in interface IActiveView
Parameters:
hDC - The hDC (A COM typedef) (in)
trackCancel - A reference to a com.esri.arcgis.system.ITrackCancel (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

output

public void output(int hDC,
                   int dpi,
                   tagRECT pixelBounds,
                   IEnvelope visibleBounds,
                   ITrackCancel trackCancel)
            throws IOException,
                   AutomationException
Renders the view to the specified DC.

Description

This method is used to draw to a non-app window hDC (see Windows GDI for more info). The ArcMap printing and exporting commands use this method. When drawing to an hWnd, normally IActiveView::Draw is used instead of this method because it handles caching and scrollbars.

Remarks

Parameter use is as follows:

hDC - Output device.
dpi - Dots per inch (resolution). If Null is passed then this defaults to the resolution of the hDC. If that cannot be sampled, then this defaults to the window resolution.
pixelBounds - Device rectangle specified in pixels.
VisibleBounds - Zoom extent. If Null is passed then this defaults to the current visible extent.

All other display attributes are copied from the ActiveView.

If you want to draw the data frame to a 640x480 bitmap for example, specify the following parameter values:

dpi - 0
pixel bounds - { 0, 0, 640, 480 }
visible bounds - 0

If you want to create a bitmap that will print 8.5 x 11 on a 300 DPI printer, specify the following parameter values:

dpi - 300
pixel bounds - { 0, 0, 8.5 * dpi, 11 * dpi }
visible bounds - 0

If you want to zoom to a certain location and draw it on a 300x300 bitmap, specify the following parameter values:

dpi - 0
pixel bounds - { 0, 0, 300, 300 }
visible bounds - { -45.0, 44.0, -44.0, 45.0 }

The value of IDisplayTransformation::Resolution does not affect the results of this method.

The value of IOutputRasterSettings::ResampleRatio does affect the results of the this method. When rasters are drawn, they get resampled as specified in this attribute.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
output in interface IActiveView
Parameters:
hDC - The hDC (A COM typedef) (in)
dpi - The dpi (in)
pixelBounds - A Structure: com.esri.arcgis.display.tagRECT (in)
visibleBounds - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
trackCancel - A reference to a com.esri.arcgis.system.ITrackCancel (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

refresh

public void refresh()
             throws IOException,
                    AutomationException
Causes the entire view to draw.

Remarks

IActiveView::Refresh invalidates all of the caches. This is a very inefficient operation; typically data from just one source has to be reread from the database and the rest can be drawn from cache. IActiveView::PartialRefresh uses it's knowledge of the cache layout to invalidate as little as possible and should be used whenever possible.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
refresh in interface IActiveView
Specified by:
refresh in interface IViewRefresh
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
esriViewDrawPhase, IGlobeLayerProperties2, IActiveView.partialRefresh(int, java.lang.Object, com.esri.arcgis.geometry.IEnvelope), IScreenDisplay.invalidate(com.esri.arcgis.geometry.IEnvelope, boolean, short), IActiveView.getScreenCacheID(int, java.lang.Object), IActiveView.refresh()

partialRefresh

public void partialRefresh(int phase,
                           Object data,
                           IEnvelope envelope)
                    throws IOException,
                           AutomationException
Draws the specified view phase. Use an envelope of zero to draw the entire phase.

Remarks

The main application window is controlled by a view (IActiveView). ArcMap currently has two view objects: Map (data view) and PageLayout (layout view). Each view has a ScreenDisplay object which performs drawing operations. The ScreenDisplay object also makes it possible for clients to create any number of caches. A cache is an off screen bitmap representing the application's window. Instead of drawing directly to the screen, graphics are drawn into caches, then the caches are drawn on the screen. When the application's window is obscured and requires redrawing, it is done so from the caches instead of from a database. In this way, caches improve drawing performance - bitmap rendering is faster than reading and displaying data from a database.

In general, the Map creates three caches: one for all the layers, another if there are annotation or graphics, and a third cache if there is a feature selection. A layer can create its own private cache if it sets ILayer::Cached equal to TRUE. In this case, the Map will create a separate cache for the layer and groups the layers above and below it into different caches.

IActiveView::PartialRefresh uses its knowledge of the cache layout to invalidate as little as possible. IActiveView::Refresh , on the other hand, invalidates all the caches which is very inefficient. Use PartialRefresh whenever possible.

Both PartialRefresh and Refresh call IScreenDisplay::Invalidate which sets a flag clients watch for. Clients draw a cache from scratch (the database) if its flag is set to true, and from cache if the flag is set to false.

The following table shows the phases each view supports and what they map to:

phase Map Layout
esriViewBackground Map grids Page/snap grid
esriViewGeography Layers Unused
*esriViewGeoSelection Feature selection Unused
esriViewGraphics Labels/graphics Graphics
esriViewGraphicSelection Graphic selection Element selection
esriViewForeground Unused Snap guides

To specify multiple draw phases, combine individual phases together using a bitwise OR. This is equivalent to adding together the integer enumeration values. For example, pass 6 to invalidate both the esriViewGeography (2) and esriViewGeoSelection (4) phases.

Use the data parameter to invalidate just a specific piece of data. For example, if a layer is loaded and its cache property is set to TRUE, this layer alone can be invalidated. A tracking layer is a good example of this.

The envelope parameter specifies a region to invalidate. For example, if a graphic element is added, it is usually only necessary to invalidate the immediate area surrounding the new graphic.

Both the data and envelope parameters are optional.

*When selecting features, you must call PartialRefresh twice, once before and once after the selection operation.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
partialRefresh in interface IActiveView
Specified by:
partialRefresh in interface IViewRefresh
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
data - A reference to another Object (IUnknown) (in)
envelope - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
esriViewDrawPhase, IGlobeLayerProperties2, IActiveView.partialRefresh(int, java.lang.Object, com.esri.arcgis.geometry.IEnvelope), IScreenDisplay.invalidate(com.esri.arcgis.geometry.IEnvelope, boolean, short), IActiveView.getScreenCacheID(int, java.lang.Object), IActiveView.refresh()

clear

public void clear()
           throws IOException,
                  AutomationException
Empties the view contents.

Remarks

The Map object's implementation of Clear deletes all of the Layers in the Map (IMap::ClearLayers ), removes all MapSurrounds (IMap::ClearSurrounds ), removes all bookmarks (IMapBookMarks::RemoveAllBookMarks), and resets the extent stack. Clear does not refresh the active view however.

Clear on PageLayout deletes all Elements, including MapFrames which hold a Map, resets the extent stack, and a new Map is created - there must always be a focus map.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

printerChanged

public void printerChanged(IPrinter printer)
                    throws IOException,
                           AutomationException
Called by application when printer changes.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
printerChanged in interface IActiveView
Parameters:
printer - A reference to a com.esri.arcgis.output.IPrinter (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

contentsChanged

public void contentsChanged()
                     throws IOException,
                            AutomationException
Called by clients when view objects are modified.

Remarks

After modifying the contents view (table of contents), use this method to fire the IActiveViewEvents::ContentsChanged event so that clients listening for this event can respond accordingly.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
contentsChanged in interface IActiveView
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IActiveViewEvents.contentsChanged(com.esri.arcgis.carto.IActiveViewEventsContentsChangedEvent)

onMessage

public void onMessage(int msg,
                      int wParam,
                      int lParam)
               throws IOException,
                      AutomationException
Call from your application's message loop to enable automatic resizing and keyboard accelerators.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
onMessage in interface IActiveView
Parameters:
msg - The msg (in)
wParam - The wParam (A COM typedef) (in)
lParam - The lParam (A COM typedef) (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getContextMenu

public void getContextMenu(double x,
                           double y,
                           IUID[] clsidMenu)
                    throws IOException,
                           AutomationException
Called when a context menu should be displayed at the given xy location. Return menu that should be displayed.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getContextMenu in interface IActiveView
Parameters:
x - The x (in)
y - The y (in)
clsidMenu - A reference to a com.esri.arcgis.system.IUID (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setElementSelectionByRef

public void setElementSelectionByRef(ISelection selectionObject)
                              throws IOException,
                                     AutomationException
Object to use for element selection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setElementSelectionByRef in interface IViewManager
Parameters:
selectionObject - A reference to a com.esri.arcgis.carto.ISelection (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IActiveView.getSelection()

getElementSelection

public ISelection getElementSelection()
                               throws IOException,
                                      AutomationException
Object to use for element selection.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getElementSelection in interface IViewManager
Returns:
A reference to a com.esri.arcgis.carto.ISelection
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IGraphicsContainerSelect.getSelectedElements()

setConserveMemory

public void setConserveMemory(boolean flag)
                       throws IOException,
                              AutomationException
Indicates whether to be conservative when allocating resources.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

isConserveMemory

public boolean isConserveMemory()
                         throws IOException,
                                AutomationException
Indicates whether to be conservative when allocating resources.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isConserveMemory in interface IViewManager
Returns:
The flag
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setTopFilterPhase

public void setTopFilterPhase(int phase)
                       throws IOException,
                              AutomationException
The highest phase in the drawing order that uses a display filter. Clients should set this when they draw in response to AfterDraw and they use a display filter.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
setTopFilterPhase in interface IViewManager
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getTopFilterPhase

public int getTopFilterPhase()
                      throws IOException,
                             AutomationException
The highest phase in the drawing order that uses a display filter. Clients should set this when they draw in response to AfterDraw and they use a display filter.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getTopFilterPhase in interface IViewManager
Returns:
A com.esri.arcgis.carto.esriViewDrawPhase constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setTopFilterIndex

public void setTopFilterIndex(int phaseIndex)
                       throws IOException,
                              AutomationException
Phase index that supplements TopFilterPhase. Clients should set the item index here if they draw in response to AfterDrawItem and they use a display filter. TopFilterPhase must also be specified.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getTopFilterIndex

public int getTopFilterIndex()
                      throws IOException,
                             AutomationException
Phase index that supplements TopFilterPhase. Clients should set the item index here if they draw in response to AfterDrawItem and they use a display filter. TopFilterPhase must also be specified.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getTopFilterIndex in interface IViewManager
Returns:
The phaseIndex
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setOutputBandSize

public void setOutputBandSize(int kilobytes)
                       throws IOException,
                              AutomationException
Size allocated for each band when banding output.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getOutputBandSize

public int getOutputBandSize()
                      throws IOException,
                             AutomationException
Size allocated for each band when banding output.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getOutputBandSize in interface IViewManager
Returns:
The kilobytes
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isUsesPageCoordinates

public boolean isUsesPageCoordinates()
                              throws IOException,
                                     AutomationException
Indicates whether view uses page coordinates.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isUsesPageCoordinates in interface IViewManager
Returns:
The usesPageCoordinates
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isVerboseEvents

public boolean isVerboseEvents()
                        throws IOException,
                               AutomationException
Indicates whether to expand or limit the number of events that are fired. The following events are not fired if VerboseEvents is false: AfterItemDraw.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isVerboseEvents in interface IViewManager
Returns:
The verboseEvents
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setVerboseEvents

public void setVerboseEvents(boolean verboseEvents)
                      throws IOException,
                             AutomationException
Indicates whether to expand or limit the number of events that are fired. The following events are not fired if VerboseEvents is false: AfterItemDraw.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

isDelayBackgroundDraw

public boolean isDelayBackgroundDraw()
                              throws IOException,
                                     AutomationException
Indicates if the background should draw immediately. Set to true to eliminate flashing during animation.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isDelayBackgroundDraw in interface IViewManager
Returns:
The flag
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setDelayBackgroundDraw

public void setDelayBackgroundDraw(boolean flag)
                            throws IOException,
                                   AutomationException
Indicates if the background should draw immediately. Set to true to eliminate flashing during animation.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

isExternalDrawing

public boolean isExternalDrawing(int phase)
                          throws IOException,
                                 AutomationException
Indicates if external clients are drawing in response to the specified phase.

Product Availability

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

Specified by:
isExternalDrawing in interface IViewManager
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
Returns:
The externalDrawing
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setExternalDrawing

public void setExternalDrawing(int phase,
                               boolean externalDrawing)
                        throws IOException,
                               AutomationException
Indicates if external clients are drawing in response to the specified phase.

Product Availability

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

Specified by:
setExternalDrawing in interface IViewManager
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
externalDrawing - The externalDrawing (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isDrawing

public boolean isDrawing()
                  throws IOException,
                         AutomationException
Indicates whether the view is currently drawing or not.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isDrawing in interface IViewRefresh
Returns:
The drawing
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isProgressiveDrawing

public boolean isProgressiveDrawing()
                             throws IOException,
                                    AutomationException
Indicates whether the view should progressively update the window during drawing. False means just update the window once when all rendering is complete.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isProgressiveDrawing in interface IViewRefresh
Returns:
The flag
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setProgressiveDrawing

public void setProgressiveDrawing(boolean flag)
                           throws IOException,
                                  AutomationException
Indicates whether the view should progressively update the window during drawing. False means just update the window once when all rendering is complete.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

partialRefreshShape

public void partialRefreshShape(int phase,
                                Object data,
                                IGeometry geometry,
                                double symbolSizePoints)
                         throws IOException,
                                AutomationException
Refreshes the specified shape on the specified view phase. Use symbolSizePoints to indicate point and line sizes.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
partialRefreshShape in interface IViewRefresh
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
data - A reference to another Object (IUnknown) (in)
geometry - A reference to a com.esri.arcgis.geometry.IGeometry (in)
symbolSizePoints - The symbolSizePoints (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

animationRefresh

public void animationRefresh(int phase,
                             Object data,
                             IEnvelope envelope)
                      throws IOException,
                             AutomationException
Use to quickly redraw a phase that has it's own cache, i.e., a tracking layer. Tradeoffs are made to ensure fast redrawing at the expense of quality.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
animationRefresh in interface IViewRefresh
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
data - A reference to another Object (IUnknown) (in)
envelope - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

animationRefreshShape

public void animationRefreshShape(int phase,
                                  Object data,
                                  IGeometry geometry,
                                  double symbolSizePoints)
                           throws IOException,
                                  AutomationException
Use to quickly redraw a phase that has it's own cache, i.e., a tracking layer. Tradeoffs are made to ensure fast redrawing at the expense of quality. See PartialRefreshShape for more info.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
animationRefreshShape in interface IViewRefresh
Parameters:
phase - A com.esri.arcgis.carto.esriViewDrawPhase constant (in)
data - A reference to another Object (IUnknown) (in)
geometry - A reference to a com.esri.arcgis.geometry.IGeometry (in)
symbolSizePoints - The symbolSizePoints (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

refreshItem

public void refreshItem(Object data)
                 throws IOException,
                        AutomationException
Use to redraw a specific item and the content above it. When adding items to the view (i.e., layers or graphics). Refresh can be optimized by only drawing the newly added items.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

refreshCaches

public void refreshCaches()
                   throws IOException,
                          AutomationException
Reallocate the display caches. Causes a full redraw. Normally caches are automatically maintained. Use this sparingly when programatically changing attributes that affect caching such as ILayer::Cached flag.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

next

public IElement next()
              throws IOException,
                     AutomationException
Returns the next graphic in the container.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

reset

public void reset()
           throws IOException,
                  AutomationException
Reset internal cursor so that Next returns the first element.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

addElement

public void addElement(IElement element,
                       int zorder)
                throws IOException,
                       AutomationException
Add a new graphic element to the layer.

Description

This method adds the input element the graphics container referenced. The parameter zorder is currently not utilized by all of the IGraphicsContainer implementations and is typically set to 0 when calling this method.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
addElement in interface IGraphicsContainer
Parameters:
element - A reference to a com.esri.arcgis.carto.IElement (in)
zorder - The zorder (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

addElements

public void addElements(IElementCollection elements,
                        int zorder)
                 throws IOException,
                        AutomationException
Add new graphic elements to the layer.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
addElements in interface IGraphicsContainer
Parameters:
elements - A reference to a com.esri.arcgis.carto.IElementCollection (in)
zorder - The zorder (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

deleteElement

public void deleteElement(IElement element)
                   throws IOException,
                          AutomationException
Delete the given element.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

deleteAllElements

public void deleteAllElements()
                       throws IOException,
                              AutomationException
Delete all the elements.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

moveElementToGroup

public void moveElementToGroup(IElement element,
                               IGroupElement group)
                        throws IOException,
                               AutomationException
Move the element from the container to the group.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
moveElementToGroup in interface IGraphicsContainer
Parameters:
element - A reference to a com.esri.arcgis.carto.IElement (in)
group - A reference to a com.esri.arcgis.carto.IGroupElement (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

moveElementFromGroup

public void moveElementFromGroup(IGroupElement group,
                                 IElement element,
                                 int zorder)
                          throws IOException,
                                 AutomationException
Move the element from the group to the container.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
moveElementFromGroup in interface IGraphicsContainer
Parameters:
group - A reference to a com.esri.arcgis.carto.IGroupElement (in)
element - A reference to a com.esri.arcgis.carto.IElement (in)
zorder - The zorder (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

locateElements

public IEnumElement locateElements(IPoint point,
                                   double tolerance)
                            throws IOException,
                                   AutomationException
Returns the elements at the given coordinate.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
locateElements in interface IGraphicsContainer
Parameters:
point - A reference to a com.esri.arcgis.geometry.IPoint (in)
tolerance - The tolerance (in)
Returns:
A reference to a com.esri.arcgis.carto.IEnumElement
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

locateElementsByEnvelope

public IEnumElement locateElementsByEnvelope(IEnvelope envelope)
                                      throws IOException,
                                             AutomationException
Returns the elements inside the given envelope.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
locateElementsByEnvelope in interface IGraphicsContainer
Parameters:
envelope - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
Returns:
A reference to a com.esri.arcgis.carto.IEnumElement
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findFrame

public IFrameElement findFrame(Object frameObject)
                        throws IOException,
                               AutomationException
Find the frame that contains the specified object.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
findFrame in interface IGraphicsContainer
Parameters:
frameObject - A Variant (in)
Returns:
A reference to a com.esri.arcgis.carto.IFrameElement
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

updateElement

public void updateElement(IElement element)
                   throws IOException,
                          AutomationException
The graphic element's properties have changed.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getElementOrder

public Object getElementOrder(IEnumElement elements)
                       throws IOException,
                              AutomationException
Private order object. Used to undo ordering operations.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getElementOrder in interface IGraphicsContainer
Parameters:
elements - A reference to a com.esri.arcgis.carto.IEnumElement (in)
Returns:
A Variant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

putElementOrder

public void putElementOrder(Object order)
                     throws IOException,
                            AutomationException
Private order object. Used to undo ordering operations.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

bringToFront

public void bringToFront(IEnumElement elements)
                  throws IOException,
                         AutomationException
Make the specified elements draw in front of all other elements.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

sendToBack

public void sendToBack(IEnumElement elements)
                throws IOException,
                       AutomationException
Make the specified elements draw behind all other elements.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

sendBackward

public void sendBackward(IEnumElement elements)
                  throws IOException,
                         AutomationException
Move the specified elements one step closer to the bottom of the stack of elements.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

bringForward

public void bringForward(IEnumElement elements)
                  throws IOException,
                         AutomationException
Move the specified elements one step closer to the top of the stack of elements.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

selectElement

public void selectElement(IElement element)
                   throws IOException,
                          AutomationException
Selects the specified element.

Remarks

Adds the specified element to the element selection and fires the IActiveViewEvents::SelectionChanged event.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

selectElements

public void selectElements(IEnumElement elements)
                    throws IOException,
                           AutomationException
Selects the specified elements.

Remarks

Adds the specified elements to the element selection and fires the IActiveViewEvents::SelectionChanged event.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

selectAllElements

public void selectAllElements()
                       throws IOException,
                              AutomationException
Selects all elements.

Remarks

Selects all elements in the container and fires the IActiveViewEvents::SelectionChanged event.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

unselectElement

public void unselectElement(IElement element)
                     throws IOException,
                            AutomationException
Unselects the specified element.

Remarks

Removes the specified element from the element selection and fires the IActiveViewEvents::SelectionChanged event.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

unselectElements

public void unselectElements(IEnumElement elements)
                      throws IOException,
                             AutomationException
Unselects the specified elements.

Remarks

Removes the specified elements from the element selection and fires the IActiveViewEvents::SelectionChanged event.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

unselectAllElements

public void unselectAllElements()
                         throws IOException,
                                AutomationException
Unselects all elements.

Remarks

Clears the element selection and fires the IActiveViewEvents::SelectionChanged event.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getSelectedElements

public IEnumElement getSelectedElements()
                                 throws IOException,
                                        AutomationException
The selected elements.

Remarks

Returns an IEnumElement containing all of the selected elements.

An IEnumElement reference to the element selection is also available from IViewManager::ElementSelection and IActiveView::Selection (QI from ISelection).

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getSelectedElements in interface IGraphicsContainerSelect
Returns:
A reference to a com.esri.arcgis.carto.IEnumElement
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IViewManager.getElementSelection()

getElementSelectionCount

public int getElementSelectionCount()
                             throws IOException,
                                    AutomationException
The number of selected elements.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

selectedElement

public IElement selectedElement(int index)
                         throws IOException,
                                AutomationException
Returns the nth selected element. Use Selection count to get the number of selected elements.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

selectionTracker

public ISelectionTracker selectionTracker(int index)
                                   throws IOException,
                                          AutomationException
Returns the tracker for the nth selected element. Use Selection count to get the number of selected elements.

Remarks

Elements have associated selection tracker objects which provide reshaping functionality. For example, in ArcMap after adding an element, the element is drawn with a selection tracker around it and users can then drag one of the selection handles on the selection tracker to modify the element's shape.

There are several types of selection tracker objects including EnvelopeTracker, MarkerTracker, PointTracker, and PolygonTracker. When an element is first selected, an EnvelopeTracker is created for it. However, if the element has its IElementEditVertices::MovingVertices property set to TRUE, then the geometry of the element dictates the type of selection tracker created. For example, a line element will create a LineTracker.

IElement::SelectionTracker checks if the elements IElementEditVertices::MovingVertices property is set to TRUE; if so, IElementEditVertices::GetMoveVerticesSelectionTracker is called to create the appropriate tracker object for the element. If MovingVertices returns FALSE, then an EnvelopeTracker is created for the element.

In ArcMap, selecting an element creates an EnvelopeTracker but the 'Edit Vertices' command swaps the it out with a PolygonTracker or LineTracker. Some elements such as a MarkerElement, CircleElement, EllipseElement, and RectangleElement, only create EnvelopeTrackers and the vertices of the these elements cannot be edited.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
selectionTracker in interface IGraphicsContainerSelect
Parameters:
index - The index (in)
Returns:
A reference to a com.esri.arcgis.display.ISelectionTracker
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
IElement

elementSelected

public boolean elementSelected(IElement element)
                        throws IOException,
                               AutomationException
Indicates if the element is selected.

Remarks

Returns TRUE if the specified element is selected.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getDominantElement

public IElement getDominantElement()
                            throws IOException,
                                   AutomationException
Dominant element.

Remarks

The dominant element is by default the first element selected. The alignment commands make use of the dominant element to arrange elements more precisely.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

setDominantElementByRef

public void setDominantElementByRef(IElement dominantItem)
                             throws IOException,
                                    AutomationException
Dominant element.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getSelectionBounds

public IEnvelope getSelectionBounds(IDisplay display)
                             throws IOException,
                                    AutomationException
The bounds of the selection.

Product Availability

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

Specified by:
getSelectionBounds in interface IGraphicsContainerSelect
Parameters:
display - A reference to a com.esri.arcgis.display.IDisplay (in)
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.

snapShape

public void snapShape(IGeometry shape)
               throws IOException,
                      AutomationException
Snap the shape using the agents in the environment.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
snapShape in interface IGraphicSnapEnvironment
Parameters:
shape - A reference to a com.esri.arcgis.geometry.IGeometry (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSnapTolerance

public double getSnapTolerance()
                        throws IOException,
                               AutomationException
The snap tolerance in page units.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getSnapTolerance in interface IGraphicSnapEnvironment
Returns:
The tol
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setSnapTolerance

public void setSnapTolerance(double tol)
                      throws IOException,
                             AutomationException
The snap tolerance in page units.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

setSnapAgentOrder

public void setSnapAgentOrder(IArray guids)
                       throws IOException,
                              AutomationException
An array of IDs indicating how agents should be ordered.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getSnapAgentOrder

public IArray getSnapAgentOrder()
                         throws IOException,
                                AutomationException
An array of IDs indicating how agents should be ordered.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getSnapAgentCount

public int getSnapAgentCount()
                      throws IOException,
                             AutomationException
The number of snap agents.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getSnapAgent

public IGraphicSnap getSnapAgent(int index)
                          throws IOException,
                                 AutomationException
The snap agent at the specified index. The index argument is zero based.

Product Availability

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

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

clearSnapAgents

public void clearSnapAgents()
                     throws IOException,
                            AutomationException
Remove all snap agents.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

addSnapAgent

public void addSnapAgent(IGraphicSnap snapAgent)
                  throws IOException,
                         AutomationException
Add a new snap agent to the environment.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

deleteSnapAgent

public void deleteSnapAgent(IGraphicSnap snapAgent)
                     throws IOException,
                            AutomationException
Remove specified snap agent from the environment.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

enumConnectionPoints

public void enumConnectionPoints(IEnumConnectionPoints[] ppEnum)
                          throws IOException,
                                 AutomationException
enumConnectionPoints

Description

IConnectionPointContainer 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:
enumConnectionPoints in interface IConnectionPointContainer
Parameters:
ppEnum - A reference to a com.esri.arcgis.display.IEnumConnectionPoints (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findConnectionPoint

public void findConnectionPoint(GUID riid,
                                IConnectionPoint[] ppCP)
                         throws IOException,
                                AutomationException
findConnectionPoint

Description

IConnectionPointContainer 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:
findConnectionPoint in interface IConnectionPointContainer
Parameters:
riid - A Structure: com.esri.arcgis.support.ms.stdole.GUID (in)
ppCP - A reference to a com.esri.arcgis.display.IConnectionPoint (out: use single element array)
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.

pageUnitsChanged

public void pageUnitsChanged(IPageEventsPageUnitsChangedEvent theEvent)
                      throws IOException,
                             AutomationException
Fired when the units used by the page changes.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
pageUnitsChanged in interface IPageEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

pageSizeChanged

public void pageSizeChanged(IPageEventsPageSizeChangedEvent theEvent)
                     throws IOException,
                            AutomationException
Fired when the page size changes.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
pageSizeChanged in interface IPageEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

pageMarginsChanged

public void pageMarginsChanged(IPageEventsPageMarginsChangedEvent theEvent)
                        throws IOException,
                               AutomationException
Fired when the page margins change.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
pageMarginsChanged in interface IPageEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

pageColorChanged

public void pageColorChanged(IPageEventsPageColorChangedEvent theEvent)
                      throws IOException,
                             AutomationException
Fired when the page color changes.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
pageColorChanged in interface IPageEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

selectionChanged

public void selectionChanged(ISelectionEventsSelectionChangedEvent theEvent)
                      throws IOException,
                             AutomationException
Call this function to fire the selection changed event.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
selectionChanged in interface ISelectionEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

boundsUpdated

public void boundsUpdated(ITransformEventsBoundsUpdatedEvent theEvent)
                   throws IOException,
                          AutomationException
Notifies clients when the bounds is updated.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
boundsUpdated in interface ITransformEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

visibleBoundsUpdated

public void visibleBoundsUpdated(ITransformEventsVisibleBoundsUpdatedEvent theEvent)
                          throws IOException,
                                 AutomationException
Notifies clients when the visible bounds is updated.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
visibleBoundsUpdated in interface ITransformEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

deviceFrameUpdated

public void deviceFrameUpdated(ITransformEventsDeviceFrameUpdatedEvent theEvent)
                        throws IOException,
                               AutomationException
Notifies clients when the device frame is updated.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
deviceFrameUpdated in interface ITransformEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

resolutionUpdated

public void resolutionUpdated(ITransformEventsResolutionUpdatedEvent theEvent)
                       throws IOException,
                              AutomationException
Notifies clients when the resolution is updated.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
resolutionUpdated in interface ITransformEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

rotationUpdated

public void rotationUpdated(ITransformEventsRotationUpdatedEvent theEvent)
                     throws IOException,
                            AutomationException
Notifies clients when the rotation angle is updated.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
rotationUpdated in interface ITransformEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

unitsUpdated

public void unitsUpdated(ITransformEventsUnitsUpdatedEvent theEvent)
                  throws IOException,
                         AutomationException
Notifies clients when the units are updated.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
unitsUpdated in interface ITransformEvents
Parameters:
theEvent - The event
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isUsesFilter

public boolean isUsesFilter()
                     throws IOException,
                            AutomationException
Indicates if the current object draws using a filter.

Remarks

The UsesFilter property returns true when the object in question will draw with a filter. Drawing with a filter means means that an object that would normally draw as vector graphics will instead draw as raster. The UsesFilter property is particularly useful for detecting vector map layers that will be rasterized at time of print or export.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
isUsesFilter in interface IDisplayAdmin
Returns:
The usesFilter
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getPageLayout

public IPageLayout getPageLayout()
                          throws IOException,
                                 AutomationException
The PageLayout object.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getMap

public IMap getMap()
            throws IOException,
                   AutomationException
The Map object.

Remarks

The map property is not supported in the case of new map being set into the focus map of the PageLayoutControl.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

Specified by:
getMap in interface IMxdContents
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.

getActiveView

public IActiveView getActiveView()
                          throws IOException,
                                 AutomationException
The Map object.

Product Availability

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

Supported Platforms

Windows, Solaris, Linux

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

getExtensionCount

public int getExtensionCount()
                      throws IOException,
                             AutomationException
Number of extensions.

Product Availability

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

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

getExtension

public Object getExtension(int index)
                    throws IOException,
                           AutomationException
The extension at the specified index.

Product Availability

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

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

addExtension

public void addExtension(Object ext)
                  throws IOException,
                         AutomationException
Adds a new extension.

Product Availability

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

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

removeExtension

public void removeExtension(int index)
                     throws IOException,
                            AutomationException
Removes the specified extension.

Product Availability

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

Specified by:
removeExtension in interface IPageLayoutExtensions
Parameters:
index - The index (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
Throws:
IOException

readExternal

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