com.esri.arcgis.display
Class IDynamicDisplayProxy

java.lang.Object
  extended by com.esri.arcgis.interop.Dispatch
      extended by com.esri.arcgis.display.IDynamicDisplayProxy
All Implemented Interfaces:
IDynamicDisplay, Externalizable, Serializable
Direct Known Subclasses:
IDynamicDisplay2Proxy

public class IDynamicDisplayProxy
extends com.esri.arcgis.interop.Dispatch
implements IDynamicDisplay, Serializable

Provides access to Dynamic Display.

Description

IDynamicDisplay interface gives access to drawing methods that render dynamic items using map coordinates, as well as access to an instance of the Dynamic Glyph Factory object. The Dynamic Glyph Factory object is a singleton object, which is used to create and delete dynamic glyphs and then can be used with the dynamic symbols in order to render the Dynamic items.

Remarks

The IDynamicDisplay interface is passed in to the callback draw methods: IDynamicLayer.DrawDynamicLayer, IDynamicMapEvents.BeforeDynamicDraw, and IDynamicMapEvents.AfterDynamicDraw.

The drawing methods can only be used in one of the callback draw methods with the following specific context:

  1. In the IDynamicLayer.DrawDynamicLayer method.
    It is recommended to use the DynamicGlyphFactory in the esriDynamicDrawPhase.esriDDPImmediate dynamic-draw-phase.
  2. IDynamicMapEvents.AfterDynamicDraw method (event handler).
    Only with the dynamic-map-draw-phase esriDynamicMapDrawPhase.esriDMDPDynamicLayers.
  3. IDynamicMapEvents.BeforeDynamicDraw method (event handler).
    Only with the dynamic-map-draw-phase esriDynamicMapDrawPhase.esriDMDPDynamicLayers.

Any usage of the DynamicDisplay drawing API (or OpenGL API) in any other context will result in an unknown behavior.

Product Availability

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

See Also:
Serialized Form

Field Summary
 boolean noncastable
           
 
Fields inherited from class com.esri.arcgis.interop.Dispatch
DISPATCH_METHOD, DISPATCH_PROPERTYGET, DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF, objRef
 
Constructor Summary
  IDynamicDisplayProxy()
           
  IDynamicDisplayProxy(Object obj)
           
protected IDynamicDisplayProxy(Object obj, String iid)
           
 
Method Summary
 void addListener(String iidStr, Object theListener, Object theSource)
           
 void drawLine(IPoint startPoint, IPoint endPoint)
          Draws a line between the specified points on the dynamic display.
 void drawMarker(IPoint point)
          Draws a marker at the specified point on the dynamic display.
 void drawMultipleLines(IPointCollection pointCollection)
          Draws specified lines on the dynamic display.
 void drawMultipleMarkers(IPointCollection pointCollection)
          Draws a marker at the specified points on the dynamic display.
 void drawPolygon(IPointCollection pointCollection)
          Draws specified polygon with fill and line on the dynamic display.
 void drawPolyline(IPointCollection pointCollection)
          Draws specified polyline on the dynamic display.
 void drawRectangle(IEnvelope envelope)
          Draws specified rectangle with fill and line on the dynamic display.
 void drawText(IPoint point, String text)
          Draws text at the specified point on the dynamic display.
 IDynamicGlyphFactory getDynamicGlyphFactory()
          Retrieves the dynamic glyph factory.
 void removeListener(String iidStr, Object theListener)
           
 
Methods inherited from class com.esri.arcgis.interop.Dispatch
bindUsingMoniker, constructVtblPosTable, convertToNative, cookieForListener, createDispatch, createObjrefMonikerDisplayName, equals, getActiveObject, getActiveObject, getDefaultProperty, getDispatchIdOfName, getLastErrorCode, getMtsObjectContext, getObjRef, getPropertyByName, getPropertyByName, getVtblPos, hashCode, initDispatch, invoke, invokeMethodByName, invokeMethodByName, invokeMethodByName, invokePropertyGetByName, invokePropertyPutByName, invokePropertyPutByRefByName, isNativeMode, isObjRef, optimizedVtblInvoke, queryInterface, readExternal, release, setNativeMode, setPropertyByName, toString, vtblInvoke, writeExternal
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

noncastable

public boolean noncastable
Constructor Detail

IDynamicDisplayProxy

public IDynamicDisplayProxy()

IDynamicDisplayProxy

public IDynamicDisplayProxy(Object obj)
                     throws IOException
Throws:
IOException

IDynamicDisplayProxy

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

addListener

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

removeListener

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

getDynamicGlyphFactory

public IDynamicGlyphFactory getDynamicGlyphFactory()
                                            throws IOException,
                                                   AutomationException
Retrieves the dynamic glyph factory.

Remarks

Use the dynamic glyph factory object in order to create and delete dynamic glyphs. The dynamic glyphs can be used with the Dynamic Symbols in order to render Dynamic Items.

The Dynamic Glyphs Factory is a singleton object; therefore you can always co-create it in order to use it to create and delete dynamic glyphs.
Performance wise, it is preferable to create the dynamic glyphs in the context of the IDynamicLayer’s DrawDynamicLayer method, in the esriDDPImmediate dynamic-draw-phase, or in the context of the IDynamicMapEvents BeofreDynamicDraw method, in the esriDMDPDynamicLayers dynamic-map-draw-phase, while casting the passed in IDynamicDisplay interface to IDynamicGlyphFactory.

Product Availability

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

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

drawMultipleMarkers

public void drawMultipleMarkers(IPointCollection pointCollection)
                         throws IOException,
                                AutomationException
Draws a marker at the specified points on the dynamic display.

Remarks

The markers will be rendered according to the current Dynamic Marker Symbol attributes, as described in esriDynamicSymbolType constants.

Using this method is useful when you need to draw multiple markers that look the same in different locations, for example drawing indication markers on a polyline's or a polygon's vertices.

Product Availability

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

In order to manage your dynamic items you should keep them in arrays of WKSPoint and have an instance of a Multipoint class (as IPointCollection). In order efficiently update the items you should be using IGeometryBridge2 interface

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

drawMarker

public void drawMarker(IPoint point)
                throws IOException,
                       AutomationException
Draws a marker at the specified point on the dynamic display.

Remarks

The marker will be rendered according to the current Dynamic Marker Symbol attributes, as described in esriDynamicSymbolType constants.

Product Availability

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

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

drawPolygon

public void drawPolygon(IPointCollection pointCollection)
                 throws IOException,
                        AutomationException
Draws specified polygon with fill and line on the dynamic display.

Remarks

The fill will be rendered according to the current Dynamic Fill Symbol attributes, as described inesriDynamicSymbolType, and the lines will be rendered according to the current Dynamic Line Symbol attributes, as described in esriDynamicSymbolType

Product Availability

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

In order to manage your dynamic polygon, you should keep it as an array of WKSPoint (do not forget to copy the first point at the end of the array) and have an instance of a Polygon geometry class in your application (as IPointCollection). In order efficiently update the polygon geometry you should be using IGeometryBridge2 interface.

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

drawMultipleLines

public void drawMultipleLines(IPointCollection pointCollection)
                       throws IOException,
                              AutomationException
Draws specified lines on the dynamic display.

Remarks

The lines will be rendered according to the current Dynamc Line Symbol attributes, as described in esriDynamicSymbolType constants.

Product Availability

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

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

drawLine

public void drawLine(IPoint startPoint,
                     IPoint endPoint)
              throws IOException,
                     AutomationException
Draws a line between the specified points on the dynamic display.

Remarks

The line will be rendered according to the current Dynamic Line Symbol attributes, as described in esriDynamicSymbolType constants.

Product Availability

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

Specified by:
drawLine in interface IDynamicDisplay
Parameters:
startPoint - A reference to a com.esri.arcgis.geometry.IPoint (in)
endPoint - A reference to a com.esri.arcgis.geometry.IPoint (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

drawPolyline

public void drawPolyline(IPointCollection pointCollection)
                  throws IOException,
                         AutomationException
Draws specified polyline on the dynamic display.

Remarks

The lines will be rendered according to the current Dynamic Line Symbol attributes, as described in esriDynamicSymbolType constants.

Product Availability

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

In order to manage your dynamic polyline, you should keep it as an array of WKSPoint and have an instance of a Polyline geometry class in your application (as IPointCollection). In order efficiently update the polyline geometry you should be using IGeometryBridge2 interface

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

drawRectangle

public void drawRectangle(IEnvelope envelope)
                   throws IOException,
                          AutomationException
Draws specified rectangle with fill and line on the dynamic display.

Remarks

Similar to the DrawPolygon method, the fill will be rendered according to the current Dynamic Fill Symbol attributes, and the lines will be rendered according to the current Dynamic Line Symbol attributes, as described in esriDynamicSymbolType constants.

Product Availability

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

Specified by:
drawRectangle in interface IDynamicDisplay
Parameters:
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.

drawText

public void drawText(IPoint point,
                     String text)
              throws IOException,
                     AutomationException
Draws text at the specified point on the dynamic display.

Remarks

The text will be rendered according to the current Dynamic Text Symbol attributes, as described in esriDynamicSymbolType constants.

Using the Dynamic Text Symbol, you can set the text to have a text box that will use the Dynamic Fill Symbol for Background fill, and the Dynamic Line Symbol for outline. Please refer to IDynamicSymbolProperties2.TextBoxUseDynamicFillSymbol and IDynamicSymbolProperties2.TextBoxUseDynamicLineSymbol boolean properties.

Product Availability

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

Specified by:
drawText in interface IDynamicDisplay
Parameters:
point - A reference to a com.esri.arcgis.geometry.IPoint (in)
text - The text (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.