|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IMapFrame
Provides access to the members that control the map element object.
IMapFrame is the default interface for the MapFrame object. The main purpose of the interface is to give the developer access to the map object stored within the frame, and it's associated locator rectangles.
MapFrame
,
IFrameElement
Method Summary | |
---|---|
void |
addLocatorRectangle(ILocatorRectangle locator)
Add a new locator rectangle to the data frame. |
IMapSurroundFrame |
createSurroundFrame(IUID clsid,
IMapSurround optionalStyle)
Returns the map surround frame element of the type given in clsid. |
IGraphicsContainer |
getContainer()
The frame's container. |
int |
getExtentType()
The way in which the map extent of the frame is specified. |
int |
getLocatorRectangleCount()
The number of locator rectangles. |
IMap |
getMap()
The associated map. |
IEnvelope |
getMapBounds()
The bounds of the map displayed by the frame. |
double |
getMapScale()
The scale at which the map should be displayed. |
ILocatorRectangle |
locatorRectangle(int index)
Returns the locator rectangle at the specified index. |
void |
removeAllLocatorRectangles()
Remove all the locator rectangles from the data frame. |
void |
removeLocatorRectangle(ILocatorRectangle locator)
Remove a locator rectangle from the data frame. |
void |
setContainerByRef(IGraphicsContainer container)
The frame's container. |
void |
setExtentType(int type)
The way in which the map extent of the frame is specified. |
void |
setMapBounds(IEnvelope bounds)
The bounds of the map displayed by the frame. |
void |
setMapByRef(IMap map)
The associated map. |
void |
setMapScale(double scale)
The scale at which the map should be displayed. |
Methods inherited from interface com.esri.arcgis.carto.IFrameElement |
---|
getBackground, getBorder, getObject, getThumbnail, isDraftMode, setBackground, setBorder, setDraftMode |
Method Detail |
---|
IMap getMap() throws IOException, AutomationException
The Map property will return the map object contained within the frame. Use this interface when you want to get the map.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
void setMapByRef(IMap map) throws IOException, AutomationException
map
- A reference to a com.esri.arcgis.carto.IMap (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
IGraphicsContainer getContainer() throws IOException, AutomationException
The Container property provides access to the PageLayout object that the MapFrame object resides within. The back pointer to the PageLayout is needed so that the container can be refreshed when the MapFrame is updated via a connection point (i.e., not through the PageLayout itself).
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
void setContainerByRef(IGraphicsContainer container) throws IOException, AutomationException
container
- A reference to a com.esri.arcgis.carto.IGraphicsContainer (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
int getExtentType() throws IOException, AutomationException
The ExtentType property is used to set or retrieve the method used to specify the extent of the map within the frame. There are three valid extent types that can be used:
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
void setExtentType(int type) throws IOException, AutomationException
type
- A com.esri.arcgis.carto.esriExtentTypeEnum constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
double getMapScale() throws IOException, AutomationException
The MapScale property returns or sets the current scale for the map. Use this property to obtain or update the scale. If updating the scale, be sure the ExtentType is set to esriExtentScale.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
void setMapScale(double scale) throws IOException, AutomationException
scale
- The scale (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
IEnvelope getMapBounds() throws IOException, AutomationException
The MapBounds property returns or sets the boundary (extent) of the map being shown in the frame. Use this property when you want to explicitly specify the coordinates of the data shown within the frame.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
void setMapBounds(IEnvelope bounds) throws IOException, AutomationException
bounds
- A reference to a com.esri.arcgis.geometry.IEnvelope (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
IMapSurroundFrame createSurroundFrame(IUID clsid, IMapSurround optionalStyle) throws IOException, AutomationException
CreateSurroundFrame is used to create a new map surround element (north arrow, scale bar, etc.) based on the current map frame. For instance, if I create a new scale bar with CreateSurroundFrame, the scale bar will be related to the map frame and updates to the map within the frame will be reflected in the scale bar.
Use this method when you want to create a new map surround object related to the current map frame.
THE CLSID paramter refers to the Class ID of the object that will be created and housed in the frame. Common Class IDs used in this paramter are:
{6589F147-F7F7-11d2-B872-00600802E603} AlternatingScaleBar
{6589F148-F7F7-11d2-B872-00600802E603} DoubleAlternatingScaleBar
{6589F143-F7F7-11d2-B872-00600802E603} HollowScaleBar
{7A3F91E4-B9E3-11d1-8756-0000F8751720} Legend
{7A3F91E3-B9E3-11d1-8756-0000F8751720} MapInset
{7A3F91DF-B9E3-11d1-8756-0000F8751720} MapTitle
{7A3F91DD-B9E3-11d1-8756-0000F8751720} MarkerNorthArrow
{7A3F91DE-B9E3-11d1-8756-0000F8751720} Overview
{6589F140-F7F7-11d2-B872-00600802E603} ScaleLine
{7A3F91DC-B9E3-11d1-8756-0000F8751720} ScaleText
{6589F146-F7F7-11d2-B872-00600802E603} SingleDivisionScaleBar
{6589F141-F7F7-11d2-B872-00600802E603} SteppedScaleLine
clsid
- A reference to a com.esri.arcgis.system.IUID (in)optionalStyle
- A reference to a com.esri.arcgis.carto.IMapSurround (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void addLocatorRectangle(ILocatorRectangle locator) throws IOException, AutomationException
AddLocatorRectangle is used to add a new locator rectangle to the current MapFrame. A locator rectangle represents the extent of another map frame in the page layout. Use this method to add a reference locator to the map frame.
locator
- A reference to a com.esri.arcgis.carto.ILocatorRectangle (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
void removeLocatorRectangle(ILocatorRectangle locator) throws IOException, AutomationException
RemoveLocatorRectangle is used to remove the specified locator from the MapFrame. Use this method when you have several locators in the frame and you only want to remove a specific one.
locator
- A reference to a com.esri.arcgis.carto.ILocatorRectangle (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
void removeAllLocatorRectangles() throws IOException, AutomationException
RemoveAllLocatorRectangles is used to remove all of the locator rectangles within the MapFrame. Use this method when you have one or more locator rectangles and you want them deleted from the frame.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
int getLocatorRectangleCount() throws IOException, AutomationException
LocatorRectangleCount is used to return a count of all the locator rectangles within the MapFrame. Use this property to determine how many locator rectangles are in the frame.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
ILocatorRectangle locatorRectangle(int index) throws IOException, AutomationException
LocatorRectangle can be used to retrieve the specified locator from the MapFrame. Use this method when you need to obtain a specific locator rectangle and you know the index number of that object within the frame.
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.MapFrame
,
IMapFrame.getMap()
,
IMapFrame
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |