|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.esri.arcgis.interop.Dispatch
com.esri.arcgis.display.IDisplayProxy
Provides access to members that control the Display.
| Field Summary | |
static java.lang.Class |
targetClass
|
| Fields inherited from class com.esri.arcgis.interop.Dispatch |
DISPATCH_METHOD, DISPATCH_PROPERTYGET, DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF |
| Constructor Summary | |
|
IDisplayProxy()
For internal use only |
|
IDisplayProxy(java.lang.Object obj)
|
protected |
IDisplayProxy(java.lang.Object obj,
java.lang.String iid)
|
|
IDisplayProxy(java.lang.String CLSID,
java.lang.String host,
AuthInfo authInfo)
|
protected |
IDisplayProxy(java.lang.String CLSID,
java.lang.String iid,
java.lang.String host,
AuthInfo authInfo)
|
| Method Summary | |
void |
addListener(java.lang.String iidStr,
java.lang.Object theListener,
java.lang.Object theSource)
Adds a Java object to be a listener for a specific kind of event generated by the COM object. |
void |
drawMultipoint(IGeometry multipoint)
Draws specified multipoint on the display. |
void |
drawPoint(IGeometry point)
Draws specified point on the display. |
void |
drawPolygon(IGeometry polygon)
Draws specified polygon on the display. |
void |
drawPolyline(IGeometry polyline)
Draws specified line on the display. |
void |
drawRectangle(IEnvelope rectangle)
Draws specified rectangle on the display. |
void |
drawText(IGeometry shape,
java.lang.String text)
Draws specified text on the display. |
void |
finishDrawing()
Completes drawing. |
IEnvelope |
getClipEnvelope()
The bounds of the invalid region. |
ISet |
getClipEnvelopes()
The invalid region as a set of envelopes. |
IGeometry |
getClipGeometry()
User-specified clip shape. |
IDisplayTransformation |
getDisplayTransformation()
The transformation used by the display. |
IDisplayFilter |
getFilter()
Display filter. |
int |
getHDC()
The device context that the display is currently drawing to. |
int |
getHPalette()
Palette. |
IIlluminationProps |
getIlluminationProps()
Illumination properties used by the display. |
boolean |
isSuppressEvents()
Indicates if display object suppresses events. |
void |
progress(int vertexCount)
Call frequently during drawing process. |
void |
removeListener(java.lang.String iidStr,
java.lang.Object theListener)
Removes a Java object as a listener to events generated by a COM object. |
void |
setClipGeometry(IGeometry geometry)
User-specified clip shape. |
void |
setDisplayTransformation(IDisplayTransformation displayTransformation)
The transformation used by the display. |
void |
setFilterByRef(IDisplayFilter filter)
Display filter. |
void |
setHPalette(int hPalette)
Palette. |
void |
setIlluminationProps(IIlluminationProps illuminationProps)
Illumination properties used by the display. |
void |
setSuppressEvents(boolean suppressEvents)
Indicates if display object suppresses events. |
void |
setSymbol(ISymbol sym)
Sets the symbol used for drawing. |
void |
startDrawing(int hDC,
short cacheID)
Prepare the display for drawing. |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final java.lang.Class targetClass
| Constructor Detail |
public IDisplayProxy(java.lang.String CLSID,
java.lang.String host,
AuthInfo authInfo)
throws java.net.UnknownHostException,
java.io.IOException
public IDisplayProxy()
public IDisplayProxy(java.lang.Object obj)
throws java.io.IOException
protected IDisplayProxy(java.lang.Object obj,
java.lang.String iid)
throws java.io.IOException
protected IDisplayProxy(java.lang.String CLSID,
java.lang.String iid,
java.lang.String host,
AuthInfo authInfo)
throws java.io.IOException
| Method Detail |
public void addListener(java.lang.String iidStr,
java.lang.Object theListener,
java.lang.Object theSource)
throws java.io.IOException
Dispatch
addListener in class DispatchiidStr - the ID of the outgoing interface, implemented by the listenertheListener - the object to be informed of the eventstheSource - the proxy class that represents the COM class that is the source of the events
java.io.IOException
public void removeListener(java.lang.String iidStr,
java.lang.Object theListener)
throws java.io.IOException
Dispatch
removeListener in class DispatchiidStr - the ID of the outgoing interface, implemented by the listenertheListener - the object that no longer wishes to be informed of the events
java.io.IOException
public IDisplayTransformation getDisplayTransformation()
throws java.io.IOException,
AutomationException
IDisplay
getDisplayTransformation in interface IDisplayAutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void setDisplayTransformation(IDisplayTransformation displayTransformation)
throws java.io.IOException,
AutomationException
IDisplay
setDisplayTransformation in interface IDisplaydisplayTransformation - A reference to a com.esri.arcgis.display.IDisplayTransformation (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IEnvelope getClipEnvelope()
throws java.io.IOException,
AutomationException
IDisplay
getClipEnvelope in interface IDisplayAutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public ISet getClipEnvelopes()
throws java.io.IOException,
AutomationException
IDisplay
getClipEnvelopes in interface IDisplayAutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public IGeometry getClipGeometry()
throws java.io.IOException,
AutomationException
IDisplayUse the ClipGeometry property to shape the area data is drawn in. For example, if you had a map of the United States that contained many layers, you could set the ClipGeometry property on the focus Map's ScreenDisplay object equal to the geometry of a particular state thereby telling the map to only draw the data falling within the particular state's area. The ClipGeometry is used to cookie-cut all data before it is drawn.
See IMap::ClipGeometry for a more information and a sample.
getClipGeometry in interface IDisplayjava.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setClipGeometry(IGeometry geometry)
throws java.io.IOException,
AutomationException
IDisplay
setClipGeometry in interface IDisplaygeometry - A reference to a com.esri.arcgis.geometry.IGeometry (in)
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public boolean isSuppressEvents()
throws java.io.IOException,
AutomationException
IDisplayFor example, IScreenDisplay::StartDrawing sets SuppressEvents to TRUE and FinishDrawing sets it back to FALSE, this prevents all transform events from firing during the drawing.
SuppressEvents is set to FALSE by default.
isSuppressEvents in interface IDisplayAutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void setSuppressEvents(boolean suppressEvents)
throws java.io.IOException,
AutomationException
IDisplay
setSuppressEvents in interface IDisplaysuppressEvents - The suppressEvents (in)
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public IDisplayFilter getFilter()
throws java.io.IOException,
AutomationException
IDisplay
getFilter in interface IDisplayAutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void setFilterByRef(IDisplayFilter filter)
throws java.io.IOException,
AutomationException
IDisplay
setFilterByRef in interface IDisplayfilter - A reference to a com.esri.arcgis.display.IDisplayFilter (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getHPalette()
throws java.io.IOException,
AutomationException
IDisplay
getHPalette in interface IDisplayAutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void setHPalette(int hPalette)
throws java.io.IOException,
AutomationException
IDisplay
setHPalette in interface IDisplayhPalette - The hPalette (A COM typedef) (in)
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void startDrawing(int hDC,
short cacheID)
throws java.io.IOException,
AutomationException
IDisplayStartDrawing and FinishDrawing are used to manage clipping, symbols, and caching. Call StartDrawing and FinishDrawing anytime you want to draw to a device such as a display, printer, or cache (bitmap). However, if you are drawing in response to IActiveViewEvents::AfterDraw, the Map object automatically makes these calls for you.
StartDrawing has two parameters: hDc and cacheID. The hDc parameter specifies the target device where drawing will occur, usually a display, printer, or bitmap. The cacheID parameter activates a specific cache. In most cases, esriNoScreenCache should be used.
Specifying a cache sets it as the screen's active cache. When esriNoScreenCache is used, it sets the display's active cache to zero and drawing occurs directly in the device. Specify a cache when you don't want to draw to a screen directly and you instead want to draw to a cache (bitmap) that may ultimately be copied to the screen. For example, when ArcMap draws geography, it draws it to a specific cache and then the cache is copied to the screen. When the screen repaints, instead of drawing all the data from scratch again, the software checks if the cache is dirty or not and simply redraws the bitmap to save time if it can. When drawing to a cache, the hDc parameter should be the device context of the bitmap, use the IScreenDisplay::CacheMemDC property to get a particular cache's hDC.
Each time you need to change the cache you are drawing to, you must do so inside a new StartDrawing / FinishDrawing block. For example, ArcMap usually creates three caches: one for geography layers, one for graphics and annotation, and one for selections. ArcMap draws each of these phases within a separate StartDrawing / FinishDrawing block.
There are times when may need to draw shapes directly to screen without having them become part of a display cache. For example, drawing moving objects. In these cases, use IScreenDisplay::WindowDC to get the device context of the display and esriNoScreenCache as the cacheID.
If a zero is specified for the hDc parameter, the Windows API function GetDC is used to populate IScreenDisplay::WindowDC with the hDC of the main display and drawing is sent here.
StartDrawing fires the IDisplayEvents::DisplayStarted event.
startDrawing in interface IDisplayhDC - The hDC (A COM typedef) (in)cacheID - The cacheID (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public int getHDC()
throws java.io.IOException,
AutomationException
IDisplayReturns the device context specified to StartDrawing. This may be the device context of a display, cache (bitmap), or some other device such as a printer. As StartDrawing is called frequently throughout the drawing pipeline, the hDc property continually changes and is therefore safe to use only within a single StartDrawing / FinishDrawing block.
This property does not provide a value to pass to IDisplay::StartDrawing. Instead, call IDisplay::StartDrawing with a value of 0 for the hDC as this will automatically use the Windows API function GetDC to populate IScreenDisplay::WindowDC with the hDC of the main display and drawing will occur there.
getHDC in interface IDisplayAutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void finishDrawing()
throws java.io.IOException,
AutomationException
IDisplay
finishDrawing in interface IDisplayjava.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void progress(int vertexCount)
throws java.io.IOException,
AutomationException
IDisplay
progress in interface IDisplayvertexCount - The vertexCount (in)
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void drawPoint(IGeometry point)
throws java.io.IOException,
AutomationException
IDisplayDrawPoint draws a Point object with the symbol that must be specified before hand with the SetSymbol method. All draw methods must be enclosed between the calls to StartDrawing and FinishDrawing unless you are drawing in response to the IActiveViewEvents::AfterDraw event.
drawPoint in interface IDisplaypoint - A reference to a com.esri.arcgis.geometry.IGeometry (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void drawMultipoint(IGeometry multipoint)
throws java.io.IOException,
AutomationException
IDisplay
drawMultipoint in interface IDisplaymultipoint - A reference to a com.esri.arcgis.geometry.IGeometry (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void drawRectangle(IEnvelope rectangle)
throws java.io.IOException,
AutomationException
IDisplay
drawRectangle in interface IDisplayrectangle - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void drawPolyline(IGeometry polyline)
throws java.io.IOException,
AutomationException
IDisplay
drawPolyline in interface IDisplaypolyline - A reference to a com.esri.arcgis.geometry.IGeometry (in)
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
public void drawPolygon(IGeometry polygon)
throws java.io.IOException,
AutomationException
IDisplay
drawPolygon in interface IDisplaypolygon - A reference to a com.esri.arcgis.geometry.IGeometry (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void drawText(IGeometry shape,
java.lang.String text)
throws java.io.IOException,
AutomationException
IDisplay
drawText in interface IDisplayshape - A reference to a com.esri.arcgis.geometry.IGeometry (in)text - The text (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setSymbol(ISymbol sym)
throws java.io.IOException,
AutomationException
IDisplay
setSymbol in interface IDisplaysym - A reference to a com.esri.arcgis.display.ISymbol (in)
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public IIlluminationProps getIlluminationProps()
throws java.io.IOException,
AutomationException
IDisplay
getIlluminationProps in interface IDisplayjava.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
public void setIlluminationProps(IIlluminationProps illuminationProps)
throws java.io.IOException,
AutomationException
IDisplay
setIlluminationProps in interface IDisplayilluminationProps - A reference to a com.esri.arcgis.display.IIlluminationProps (in)
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||