|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IARControlDefault
Provides access to members on the control.
The IARControlDefault interface is the default dispatch interface that most development environments will automatically expose. For example, placing the ArcReaderControl in a container will typically generate an object called ArcReaderControl1. The properties and methods available directly on this object correspond to this interface, together with container specific properties and methods.
The IARControlDefault interface is a 'pure' dispatch interface, so can be extended with new properties and methods at future releases of ArcGIS. The methods and properteis are identical to the highest numbered main interface on the ArcReaderControl. For example, IARControlDefault is equivalent to IARControl, but at future releases this could become IARControl2. By using the IARControlDefault interface you are guaranteed to always have access to the latest ArcReaderControl.
There is a small performance overhead in making calls through to a pure dispatch interface, but to avoild this you can QI to a specific interface. In some development environments it is not possible to QI directly on the control to other COM interfaces, because the control is contained within a wrapper object. Use the Object property to get the real control before performing the QI.
Method Summary | |
---|---|
void |
aboutBox()
Displays a dialog of information about the control. |
boolean |
checkDocument(String sFilename)
Checks the document filename to determine if its a valid Published Map File (*.PMF), published with permission to load into the control. |
void |
copyViewToClipboard()
Copies the current map or page layout view to the clipboard. |
boolean |
esri_isEnabled()
Indicates whether the control can respond to user generated events. |
void |
esri_setEnabled(boolean rhs1)
Indicates whether the control can respond to user generated events. |
void |
exportView(int format,
String sFilename)
Export the current map or page layout view to the file. |
int |
getAppearance()
The appearance of the control. |
IARCommandInfo |
getARCommandInfo(int tool)
The ARCommandInfo contained by the control. |
IARConfiguration |
getARConfiguration()
The ARConfiguration used by the control. |
IARPageLayout |
getARPageLayout()
The page layout contained within the currently loaded document. |
IARUnitConverter |
getARUnitConverter()
The ARUnitConverter contained by the control. |
int |
getBorderStyle()
The border style of the control. |
int |
getCurrentARTool()
Current active tool for the control. |
Object |
getCurrentView()
The current map or page layout view. |
int |
getCurrentViewType()
The type of current view. |
Object |
getCustomProperty()
A property to associate data with a control. |
String |
getDocumentComment()
A comment about the currently loaded Published Map File (*.PMF). |
String |
getDocumentFilename()
The file name of the currently loaded Published Map File (*.PMF). |
int |
getHWnd()
Handle to the window associated with the control. |
int |
getMousePointer()
The mouse cursor displayed over the document. |
Object |
getObject()
A property that returns the underlying control. |
IARLayer |
getSelectedARLayer()
The selected ARLayer in the TOC. |
IARLayer |
getSwipeLayer()
The swipe layer used by the control. |
int |
getTOCWidth()
The width of the Table of Contents (TOC) in pixels. |
int |
getViewHeight()
The height of the Active View in pixels. |
int |
getViewLeft()
The number of pixels between the top of the control and the top of the Active View. |
int |
getViewTop()
The number of pixels between the left edge of the control and the left side of the Active View. |
int |
getViewWidth()
The width of the Active View in pixels. |
int |
getViewWindow()
Handle to the view window associated with the control. |
boolean |
hasDocumentPermission(int docPermission)
Indicates if the currently loaded Published Map File (*.PMF) was published with the specified permission. |
boolean |
isARWindowVisible(int win)
Indicates if the specified control window is visible. |
boolean |
isEnableFileDrop()
Indicates whether Published Map Files can be dropped onto the control. |
boolean |
isHasCustomARConfiguration()
Is the current PMF using settings stored in the PMF. |
boolean |
isShowMapTips()
Indicates if map tips are shown when the current view is a map or page layout. |
boolean |
isShowScrollbars(int viewType)
Indicates if the map and page layout scrollbars are visible. |
boolean |
isTOCVisible()
Indicates if the Table of Contents (TOC) is visible. |
void |
loadDocument(String sFilename,
String sPassword)
Loads the Published Map File (*.PMF) into the control. |
void |
printView()
Send the current map or page layout view to the printer. |
void |
refresh(boolean refreshNow)
Refresh the control's window. |
void |
reloadDocument(String sPassword)
Reloads the currently loaded Published Map File (*.PMF) back into the control. |
void |
setAppearance(int rhs1)
The appearance of the control. |
void |
setARConfigurationByRef(IARConfiguration rhs1)
The ARConfiguration used by the control. |
void |
setBorderStyle(int rhs1)
The border style of the control. |
void |
setCurrentARTool(int rhs1)
Current active tool for the control. |
void |
setCurrentViewByRef(Object rhs1)
The current map or page layout view. |
void |
setCustomProperty(Object rhs1)
A property to associate data with a control. |
void |
setDocumentFilename(String rhs1)
The file name of the currently loaded Published Map File (*.PMF). |
void |
setEnableFileDrop(boolean rhs1)
Indicates whether Published Map Files can be dropped onto the control. |
void |
setMousePointer(int rhs1)
The mouse cursor displayed over the document. |
void |
setShowMapTips(boolean rhs1)
Indicates if map tips are shown when the current view is a map or page layout. |
void |
setShowScrollbars(int viewType,
boolean rhs2)
Indicates if the map and page layout scrollbars are visible. |
void |
setSwipeLayerByRef(IARLayer rhs1)
The swipe layer used by the control. |
void |
setTOCVisible(boolean rhs1)
Indicates if the Table of Contents (TOC) is visible. |
void |
setTOCWidth(int rhs1)
The width of the Table of Contents (TOC) in pixels. |
void |
showARWindow(int win,
boolean show,
Object data)
Shows or hides the specified control window. |
void |
suppressResizeDrawing(boolean suppressResize,
int resizeHWnd)
Suppress full redraw of control during resize operations. |
void |
unloadDocument()
Unloads the currently loaded Published Map File (*.PMF) from the control. |
Method Detail |
---|
void setBorderStyle(int rhs1) throws IOException, AutomationException
rhs1
- A com.esri.arcgis.controls.esriARBorderStyle constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getBorderStyle() throws IOException, AutomationException
Returns or sets the border style of a ArcReaderControl. By default a border is drawn.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void esri_setEnabled(boolean rhs1) throws IOException, AutomationException
rhs1
- The rhs1 (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean esri_isEnabled() throws IOException, AutomationException
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setAppearance(int rhs1) throws IOException, AutomationException
rhs1
- A com.esri.arcgis.controls.esriARAppearance constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getAppearance() throws IOException, AutomationException
Returns or sets the paint style of the ArcReaderControl to either Flat or 3D. By default the appearance is flat.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void aboutBox() throws IOException, AutomationException
The AboutBox method causes a modal dialog box to display on top of the ArcReaderControl, containing information about the version and creation date of the ArcReaderControl as well as listing relevant legal and copyright information from ESRI.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void loadDocument(String sFilename, String sPassword) throws IOException, AutomationException
Loads the specified Published Map File (*.pmf) into the ArcReaderControl. Use the CheckDocument method to determine if the specified Published Map File can be loaded successfully.
If a document was password protected when it was published, the user will be prompted automatically for a password, if the password is not passed within the LoadDocument method. If an incorrect password is supplied twice in succession a custom error will be returned.
If a document in successfully loaded the CurrentView and the CurrentARTool will be set. The default CurrentARTool is specified by the ‘DefaultDataTool’ and ‘DefaultLayoutTool’ settings in the ARConfiguration. The DocumentFilename property will update itself with the path and filename of the currently loaded document, and the DocumentComment property to update itself with any comments that were supplied by the publisher of the document.
The LoadDocument method triggers the following events:
OnDocumentLoaded
OnCurrentViewChanged
OnBeforeScreenDraw
OnAfterScreenDraw
sFilename
- The sFilename (in)sPassword
- The sPassword (in, optional, pass if not required)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void unloadDocument() throws IOException, AutomationException
The UnloadDocument method removes the currently loaded PMF document from the ArcReaderControl and causes the DocumentFilename property to update itself with an empty string. At this point the ArcReaderControl is empty.
The UnloadDocument method triggers the following events:
OnDocumentUnloaded
OnCurrentViewChanged
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void reloadDocument(String sPassword) throws IOException, AutomationException
The ReloadDocument method loads the currently loaded Published Map File back into the ArcReaderControl. This resets the ArcReaderControl to the state of the Published Map File on disk, resetting the CurrentView, the extent of the CurrentView and layer visibility.
If a document was password protected when it was published, the user will be prompted automatically for a password, if the password is not passed within the ReloadDocument method. If an incorrect password is supplied twice in succession a custom error will be returned.
The ReloadDocument method triggers the following events:
OnDocumentUnloaded
OnCurrentViewChanged
OnDocumentLoaded
OnCurrentViewChanged
OnBeforeScreenDraw
OnAfterScreenDraw
sPassword
- The sPassword (in, optional, pass if not required)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setCurrentViewByRef(Object rhs1) throws IOException, AutomationException
rhs1
- A reference to another Automation Object (IDispatch) (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.Object getCurrentView() throws IOException, AutomationException
One of the most important aspects of the ArcReaderControl is the notion of its views. You can think of the view as the place where data is drawn. A view is either the ARPageLayout or the IARPageLayout::FocusARMap. Only one of these views can be visible at a time, and is known as the CurrentView. The CurrentViewType returns a constant indicating the type of CurrentView.
Setting the CurrentView triggers the OnCurrentViewChanged event. To set the CurrentView to Nothing, use the UnloadDocument method.
Setting the CurrentView property will return an error if the currently loaded document was not published with permission to ChangeView. Use the IARControlDefault::HasDocumentPermission method to determine this.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.String getDocumentComment() throws IOException, AutomationException
Returns any comments that were specified when the currently loaded document was published.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IARPageLayout getARPageLayout() throws IOException, AutomationException
The ARPageLayout object manages the layout of a page that is sent as output to a printer. The ARPageLayout will typically consist of one or more maps, together with marginalia such as scalebars, legends and titles. Use the IARPageLayout::ARMap property to access any maps present in the page layout.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void showARWindow(int win, boolean show, Object data) throws IOException, AutomationException
The ShowARWindow shows or hides the specified built in window. By default all of the esriARWindows are closed. Before using the ShowARWindow method make one or all of the following checks:
A modal window requires a response from the user, before they can interact with another part of the application. A modeless window will stay on the screen, available for use, but allow the user to interact with other parts of the application. When the LoadDocument or ReloadDocument methods are used, any modeless windows will be automatically closed.
esriARWindowsFind: A modeless dialog for finding features by their attribute values in the IARPageLayout::FocusARMap. Optionally, supply an ARLayer as the data parameter to perform the find on a particular layer. The ShowARWindow method will return an error if the currently loaded document was not published with permission to Find. Use the IARControlDefault::HasDocumentPermission method to determine this.
esriARWindowsMagnifier: A modeless window that works like a magnifying glass as it is moved over the CurrentView displaying it in more detail.
esriARWindowsSearchHelp: Not yet implemented.
esriARWindowsHelpContents: Not yet implemented.
esriARWindowsFileProperties: A modal dialog displaying file property, disabled functionality and inaccessible layer information about the currently loaded document.
esriARWindowsAddInternetSite: A modal dialog for adding an internet site. If an address is entered begining with "www" this is automatically appended with '?mode=arcreadermap' in order to open the site at the location of Published Map Files. The internet site is automatically opened within a browser and added to the esriARWindowsManageInternetSite window.
esriARWindowsManageInternetSite: A modal dialog for managing any internet sites that have previoulsy been added.
esriARWindowsInternetBrowser: Opens an internet browser at the internet site specified by the data parameter. The data parameter can either be a String consisting of a valid URL (the URL must contain ""www"") or a Long representing the index of a URL that has previously been added. Note that an index of 0 is reserved and represents the ESRI website and an index of 1 is reserved and represents the ESRI Geography Network. Any URL that has previoulsy been added will start at the index value of 2.
esriARWindowsPageSetup: A modal window for setting up the CurrentView prior to printing. The ShowARWindow method will return an error if the currently loaded document was not published with permission to Print. Use the IARControlDefault::HasDocumentPermission method to determine this.
esriARWindowsPrinter: A modal window for sending the CurrentView to a printer. The ShowARWindow method will return an error if the currently loaded document was not published with permission to Print. Use the IARControlDefault::HasDocumentPermission method to determine this.
esriARWindowsIdentify: A modeless dialog for displaying identify results when the CurrentARTool is set to esriARToolMapIdentify.The ShowARWindow method will return an error if the currently loaded document was not published with permission to Identify. Use the IARControlDefault::HasDocumentPermission method to determine this.
win
- A com.esri.arcgis.controls.esriARWindows constant (in)show
- The show (in, optional, pass true if not required)data
- A Variant (in, optional, pass null if not required)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isARWindowVisible(int win) throws IOException, AutomationException
win
- A com.esri.arcgis.controls.esriARWindows constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void suppressResizeDrawing(boolean suppressResize, int resizeHWnd) throws IOException, AutomationException
If the ArcReaderControl contains a lot of data, redrawing this data during a resize event can be costly. To increase performance you can suppress the data redraw until the resizing is complete with the SuppressResizeDrawing method. During the resize a stretched bitmap will be drawn instead.
Pass True to suppress normal drawing and draw a stretched bitmap when a resize event begins. During the resize the data is not refereshed and the captured image is stretched. As such, the image can appear pixelated when a small display area is resized to a large display area. Pass False to resume normal drawing when a resize event ends.
In development environments that do not trap the beginning and end of a resize event, the ArcReaderControl can 'watch' the hwnd supplied to the SuppressResizeDrawing method. When a form or container starts resizing the WM_ENTERSIZEMOVE windows messge is sent and the ArcReaderControl will set suppressResize to True. When windows sends the WM_EXITSIZEMOVE message the form or container is released from resizing and the the ArcReaderControl will set suppressResize to False. Pass the hwnd of the form or container to the SuppressResizeDrawing method when the form or container is initialized. Passing an hwnd of 0 will stop the ArcReaderControl watching the hwnd.
suppressResize
- The suppressResize (in)resizeHWnd
- The resizeHWnd (in, optional, pass 0 if not required)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setTOCWidth(int rhs1) throws IOException, AutomationException
rhs1
- The rhs1 (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getTOCWidth() throws IOException, AutomationException
The width of the Table of Contents (TOC) in pixels. By default the TOCWidth property is set to 180. The minimum value that can be set to the TOCWidth property is 4.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void printView() throws IOException, AutomationException
Sends the CurrentView to either the system default printer or the last printer selected in either the esriARWindowsPageSetup or esriARWindowsPrinter window.
The PrintView method will return an error if the currently loaded document was not published with permission to Print. Use the IARControlDefault::HasDocumentPermission method to determine this.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void copyViewToClipboard() throws IOException, AutomationException
Copies a bitmap of the CurrentView to the system clipboard so that it can be copied into other applications. The output will exactly reflect the state of the CurrentView as seen on the screen.
The CopyViewToClipboard method will return an error if the currently loaded document was not published with permission to CopyViewToClipboard. Use the HasDocumentPermission method to determine this.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setCurrentARTool(int rhs1) throws IOException, AutomationException
rhs1
- A com.esri.arcgis.controls.esriARTool constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getCurrentARTool() throws IOException, AutomationException
The CurrentARTool used to interact with the CurrentView. The CurrentARTool for the ARPageLayout view is independent from the CurrentARTool for the ARMap view. For example, the built in map zoom in tool maybe the CurrentARTool when the CurrentView is a map, and the built in page layout pan tool maybe the CurrentARTool when the CurrentView is a page layout. Loading a new document into the ArcReaderControl will cause the CurrentARTool property to be set for each view according to the ‘DefaultDataTool’ and ‘DefaultLayoutTool’ settings in the ARConfiguration.
Setting the CurrentARTool will change the mouse cursor and may popup a modeless dialog. For example, setting the current tool to the built in identify tool will cause the identify dialog to open. Some of the tools may change the focus map when the current view is a page layout. The CurrentARTool cannot be set to Nothing, instead set the CurrentARTool to the NoneSelected tool.
The following table lists each tool and briefly describes its function
Tool | Description |
---|---|
esriARToolNoneSelected | Use this tool if you want nothing to happen when the user interacts with the CurrentView . |
esriARToolMapZoomIn, esriARToolMApZoomOut, esriARToolMapPan | Use these tools to navigate around an ARMap regardless of the CurrentView; these tools will work on a map when the current view is a page layout. Click or drag a rectangle on the CurrentView to use the zoom tools, and depress the mouse and drag the CurrentView in a particular direction before releasing the mouse to pan. |
esriARToolLayoutZoomIn, esriARToolLayoutZoomIn, esriARToolLayoutPan | Use these tools to navigate around the ARPageLayout when it is the CurrentView. Click or drag a rectangle on the CurrentView to use the zoom tools, and depress the mouse and drag the CurrentView in a particular direction before releasing the mouse to pan. |
esriARMapIdentify, esriARMapIdentifyUsingLayer | Use these tools to identify features in the CurrentView. Click on a single feature or drag a rectangle to select multiple features in the CurrentView . The window has its own context menus; incorporates a raster viewer; and can display hyperlinks. |
esriARMapMeasure | Use this tool to measure distances and areas on an ARMap regardless of the CurrentView. Measurements are given in IARMap::DistanceUnits |
esriARMapHyperlink | Use this tool to access any hyperlinks present in the data regardless of the CurrentView . |
esriARToolCustom |
Use this to use a tool other than the built in tools. The custom tool must be a COM object that implements both ICommand and ITool. Custom tools can only be used if the PMF document was published with permission to access internal ArcObjects. Use the HasDocumentPermission method to check this. |
Setting the CurrentARTool property to the Identify, Measure or Hyperlink tools will return an error if the currently loaded document was not published with permission to Identify, Measure and access Hyperlinks. Use the IARControlDefault::HasDocumentPermission method to determine this.
Always check if a tool is enabled before setting it to the CurrentARTool property, by returning the ARCommandInfo and checking the IARCommandInfo::Enabled state. Here are some occasions when an esriARTool maybe disabled:
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean hasDocumentPermission(int docPermission) throws IOException, AutomationException
The HasDocumentPermission method determines whether the currently loaded document was published with the specified functionality permission.
When a document is published the publisher can set a variety of permissions to limit the functionality that a user has access to when viewing the document in the ArcReaderControl. These permissions should be checked and the behaviour of an application modified appropriately. For example, if permission to access hyperlinks does not exist an application should be modified so that a user can not set the current tool to the hyperlink tool.
esriARDocumentPermissionsPrint: Indicates whether permission exists to use the PrintView method and the ShowARWindow method to open the PageSetup and Printer windows.
esriARDocumentPermissionsExport: Indicates whether permission exists to use the IARControl::ExportView method.
esriARDocumentPermissionsIdentify: Indicates whether permission exists to set the CurrentARTool property to the Identify tool to use the ShowARWindow method to open the Identify window.
esriARDocumentPermissionsFind: Indicates whether permission exists to use the ShowARWindow method to open the Find window.
esriARDocumentPermissionsChangeView: Indicates whether permission exists to set the CurrentView property.
esriARDocumentPermissionsChangeLayerVisibility: Indicates whether permission exists to set the IARLayer::Visible property.
esriARDocumentPermissionsHyperlink: Indicates whether permission exists to set the CurrentARTool property to the Hyperlinks tool.
esriARDocumentPermissionsMeasure: Indicates whether permission exists to set the CurrentARTool property to the Measure tool.
esriARDocumentPermissionsViewTOC: Indicates whether permission exists to set the TOCVisible property.
esriARDocumentPermissionsOnlyInArcReader: Indicates whether permission exists for Published Map File to be loaded into the ArcReaderControl.
esriARDocumentPermissionsQueryFeatures: Indicates whether permission exists to use the IARMap::SearchARFeatures, IARMap::QueryARFeatures, IARLayer::SearchARFeatures, and IARLayer::QueryARFeatures methods.
esriARDocumentPermissionsQueryValues: Indicates whether permission exists to use the IARFeature::Value property.
esriARDocumentPermissionsCopyViewToClipboard: Indicates whether permission exists to use the CopyViewToClipboard method.
esriARDocumentPermissionsInternalObjects: Indicates whether permission exists to get the IARPageLayout::InternalObject, IARMap::InternalObject, IARLayer::InternalObject and IARFeature::InternalObject properties. This permission is true if the publisher selected "Unrestriced access to contents of Published Map" at the time of publishing.
docPermission
- A com.esri.arcgis.controls.esriARDocumentPermissions constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setShowScrollbars(int viewType, boolean rhs2) throws IOException, AutomationException
viewType
- A com.esri.arcgis.controls.esriARViewType constant (in)rhs2
- The rhs2 (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isShowScrollbars(int viewType) throws IOException, AutomationException
viewType
- A com.esri.arcgis.controls.esriARViewType constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setTOCVisible(boolean rhs1) throws IOException, AutomationException
rhs1
- The rhs1 (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isTOCVisible() throws IOException, AutomationException
Indicates whether the Table of Contents (TOC) on the left hand side of the ArcReaderControl is visible. You may want to hide the TOC to have more area for displaying data. The width of the TOC can be changed by setting the TOCWidth property to the appropriate number of pixels. By default the TOCVisible property is set to true.
Setting the TOCVisible property will return an error if the currently loaded document was not published with permission to ViewTOC. Use the IARControlDefault::HasDocumentPermission method to determine this.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getHWnd() throws IOException, AutomationException
The operating environment identifies each window, form and control in an application by assigning it a handle, or hWnd. Many ArcObjects methods and Windows API calls require the hWnd as an argument.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setShowMapTips(boolean rhs1) throws IOException, AutomationException
rhs1
- The rhs1 (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isShowMapTips() throws IOException, AutomationException
Determines whether map tips are displayed (if they exist) as the mouse moves over layer features. Map tips will be present if they were present in the ArcMap document at the time of publishing. By default the ShowMapTips property is set to true.
Map tips will only be shown when the CurrentView is an IARPageLayout::ARMap.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void refresh(boolean refreshNow) throws IOException, AutomationException
The Refresh method causes screen display area of the CurrentView to be completely redrawn by sending a windows paint event. This causes all data in the current map extent to be retieved and any map surround layout elements to be redrawn. Use the Refresh method to ensure the CurrentView is displaying the current state of the data. For example, if data is in an SDE server with many users editing the data, refreshing the CurrentView ensures the user of a ArcReaderControl application sees any new edits.
Specify whether to immediately redraw the CurrentView or whether to queue up the redraw to happen at some point in the future. For example, if there are many extent changes, but only the last extent needs displaying to the user pass False to the Refresh method. The paint event will be queued and the CurrentView will be redrawn once after the last extent change. However, if every extent change needs displaying to the user, pass True to the Refresh method. The CurrentView will be redrawn after every extent change. Likewise pass True after an extent change, but before flashing or flickering an ARFeature.
If the esriARWindows magnifier window if it is visible, the Refresh method will cause the contents of the window to be redrawn too.
refreshNow
- The refreshNow (in, optional, pass false if not required)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getCurrentViewType() throws IOException, AutomationException
Returns the type of CurrentView. If no document has been loaded esriARViewTypeNone will be returned.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IARConfiguration getARConfiguration() throws IOException, AutomationException
This is the ARConfiguration object contained within the ArcReaderControl. It is a helper object for customising the appearance and behaviour of the ArcReaderControl. It consists of many property and value settings that are stored in a template file (.art), known as an ‘ArcReader Template’.
There are various ways to manage these property and value settings:
In order for the ArcReaderControl to update itself to match any updated settings the ARConfiguration object must be set back into the ArcReaderControl.
The ArcReaderControl will initially look for an template file in
a users local profile. If no template file is found a
default configuration file will be created containing default
settings. The contents of the ARConfiguration can be stored in a
template file in the current user profile and used as an
initialization or "INI" file. The ArcReader desktop application
does this using a
file called ArcReader.art. It is recommended not to reuse this file
as it may break the ArcReader desktop application.
Instead, use a location such as:
User profile\Application Data\CompanyName\ProductName\Templates\FileName.art
Once a template has been saved it can be loaded into the ArcReaderControl to suit a particular user or application. For example, a user may have a preference about the window position of the magnifier window and whether the table of contents is displayed. When the ArcReaderControl exits (typically when the form or container is closed) the value of these settings is updated back into the ARConfiguration. Additional custom settings can be added to the ARConfiguration, to store user preferences specific to the custom application.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setARConfigurationByRef(IARConfiguration rhs1) throws IOException, AutomationException
rhs1
- A reference to a com.esri.arcgis.controls.IARConfiguration (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IARUnitConverter getARUnitConverter() throws IOException, AutomationException
The ARUnitConverter object is a helper object for firstly converting values between different esriARUnits and secondly for converting values and esriARUnits constants to strings.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.String getDocumentFilename() throws IOException, AutomationException
Returns the file name of the currently loaded document.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setDocumentFilename(String rhs1) throws IOException, AutomationException
rhs1
- The rhs1 (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean checkDocument(String sFilename) throws IOException, AutomationException
Determines whether the specified Published Map File (*.pmf) is a valid file and was published with permission to load into the ArcReaderControl.
sFilename
- The sFilename (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IARCommandInfo getARCommandInfo(int tool) throws IOException, AutomationException
tool
- A com.esri.arcgis.controls.esriARTool constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void exportView(int format, String sFilename) throws IOException, AutomationException
Exports the CurrentView with the specified filename, in the specified format. The output will exactly reflect the state of the CurrentView as seen on the screen.
The Export method will return an error if the currently loaded document was not published with permission to Export. Use the IARControlDefault::HasDocumentPermission method to determine this.
format
- A com.esri.arcgis.controls.esriARExportFormat constant (in)sFilename
- The sFilename (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setEnableFileDrop(boolean rhs1) throws IOException, AutomationException
rhs1
- The rhs1 (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isEnableFileDrop() throws IOException, AutomationException
Indicates if the ArcReaderControl will load Published Map Files (*.pmf) by the user interactively dropping files onto the ArcReaderControl from other applications such as ArcCatalog or Windows Explorer. The ArcReaderControl itself will determine if the file that has been dropped is a PMF document that can be loaded into the ArcReaderControl.
By default dragging a file over the ArcReaderControl will cause the mouse cursor to change to an ‘add data’ cursor. Setting the EnableFileDrop property to False, will cause the mouse cursor to change to a ‘no entry’ cursor when files are dragged over the ArcReaderControl.
If a document is successfully loaded the CurrentView and the CurrentARTool will be set. The default CurrentARTool is specified by the ‘DefaultDataTool’ and ‘DefaultLayoutTool’ settings in the ARConfiguration. The DocumentFilename property will update itself with the path and filename of the currently loaded document, and the DocumentComment property to update itself with any comments that were supplied by the publisher of the document.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.Object getCustomProperty() throws IOException, AutomationException
Use the CustomProperty to associate any useful data with the ArcReaderControl. This is similar to a 'Tag' property, and can be use to store strings, numbers and objects.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setCustomProperty(Object rhs1) throws IOException, AutomationException
rhs1
- A Variant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.Object getObject() throws IOException, AutomationException
In some development environments it is not possible to query interface directly on the control to other COM interfaces, beacuse the control is contained within a wrapper object. To get the real control use the Object property.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getViewTop() throws IOException, AutomationException
The top of the CurrentView display area in pixels. This will always return 0.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getViewLeft() throws IOException, AutomationException
The left of the CurrentView display area in pixels. The ViewLeft is equal to the TOCWidth + 4 (the width of the splitter that separates the TOC from the CurrentView display area).
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getViewHeight() throws IOException, AutomationException
The height of the CurrentView display area in pixels.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getViewWidth() throws IOException, AutomationException
The width of the CurrentView display area in pixels. The ViewWidth is equal to the width of the ArcReaderControl - TOCWidth - 4 (the width of the splitter that separates the TOC from the CurrentView display area).
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isHasCustomARConfiguration() throws IOException, AutomationException
This property can be used to determine if the currently loaded document has been published with an embedded ArcReader Template File (ART).
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setSwipeLayerByRef(IARLayer rhs1) throws IOException, AutomationException
rhs1
- A reference to a com.esri.arcgis.controls.IARLayer (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IARLayer getSwipeLayer() throws IOException, AutomationException
This property can be used to specify the ARLayer which is used by the esriARToolMapSwipe. Layers beneath the ArcReaderControl::SwipeLayer will be revealed when the esriARToolMapSwipe tool is used.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getViewWindow() throws IOException, AutomationException
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setMousePointer(int rhs1) throws IOException, AutomationException
rhs1
- A com.esri.arcgis.controls.esriARMousePointer constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getMousePointer() throws IOException, AutomationException
You can use MousePointer to set the system mouse pointer to be one of the standard built-in esriARMousePointers. This is useful if you want to display a wait cursor while you code performs a large process. The specified esriARMousePointer is displayed provided the ArcReaderControl::CurrentARTool is set to esriARToolNoneSelected.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IARLayer getSelectedARLayer() throws IOException, AutomationException
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |