|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ITraverseWindow2
Provides access to members that interact with the Traverse Window dialog.
ITraverseWindow2 extends the TraverseWindow functionality to allow you to set things like the the start and end points of the traverse, check if the Finish or IsClosed buttons are enabled.
ITraverseWindow2 allows courses to be added to the existing traverse within the Traverse dialog. A current workspace must be being edited for the Traverse dialog to be enabled. Also the current edit layer must be either a Polyline or a Polygon.
A StartPoint needs to be set before any courses can be added. An optional FinishPoint can exist for the traverse.
The type of course being added to the traverse depends on the CourseType. The esriCTDirectionDistance and esriCTAngleDistance courses create line segments, the esriCTCurve and esriCTTangentCurve courses create circular arc segments. The courses are defined by text values within the MeasureText, CurveParameter, CurveDirectionType and TurnDirection properties.
When the course type is DirectionDistance, MeasureText(0) is the direction of the course and MeasureText(1) is the distance of the course. For a course type of AngleDistance, MeasureText(0) is the clockwise angle between the previous segment and the new segment and MeasureText(1) is the distance of the line segment. For both the TangentCurve and Curve course types, MeasureText(0) is a text value representing the appropriate curve parameter defined by CurveParameter(0) and MeasureText(1) is a text value representing the appropriate curve parameter defined by CurveParameter(1). Any two of the CurveParameters are required to create a circular arc including Chord Length, Arc Length, Delta Angle or Radius. The TurnDirection is also required to indicate if the curve turns to the left or right If the course type is Curve, a text value in MeasureText(2) and CurveDirectionType define the direction of the curve.
Once all of the parameters have been set for a course, IsAddEnabled will test if the values are correct. Add is used to create a new course. You can test IsFinishEnabled, the Finish button is enabled once you have at least one course in the traverse. You can also remove a specific course with the Remove method.
All Directions and Angles are in the current units specified within the Editor options. Distances are in the current data frame map units, however they can also be entered with an appropriate suffix that specifies the length units. Refer to the IDistanceConverter for more on the converting distances.
To interact with specific controls on the Traverse Window dialog, the MeasureSelected, MeasureHWND and SetFocusToMeasure methods are used.
Method Summary | |
---|---|
void |
add()
Add the course that is defined by the current course parameters. |
void |
finish()
Finishes the traverse. |
ICourse |
getCourse(int index)
A reference to the ith course. |
int |
getCourseCount()
The number of courses in the traverse. |
int |
getCourseType()
The type of the course being added. |
int |
getCurveDirectionType()
If the course type is esriCTCurve, defines the direction type of the curve. |
int |
getCurveParameter(int index)
If the course type is esriCTCurve or esriCTTangentCurve, describes the type of curve paramater that the ith measure text represents. |
IPoint |
getFinishPoint()
The specified end point of the traverse. |
int |
getMeasureHWND(int index)
The handle of the ith measure text control. |
String |
getMeasureText(int index)
The ith value that defines the course to add. |
IPoint |
getStartPoint()
The specified start point of the traverse. |
int |
getTurnDirection()
If the course type is esriCTCurve or esriCTTangentCurve, indicates if the curve turns to the left or right. |
boolean |
isAddEnabled()
Indicates if the Add command on the Traverse Window dialog is enabled. |
boolean |
isClosedLoop()
Indicates if the traverse is a closed loop. |
boolean |
isFinishEnabled()
Indicates if the Finish command on the Traverse Window dialog is enabled. |
boolean |
isMeasureSelected(int index)
Indicates if the text in the ith measure is selected. |
boolean |
isVisible()
Indicates if Traverse Window is visible. |
void |
remove(int index)
Removes the ith course from the traverse. |
void |
setCourseType(int type)
The type of the course being added. |
void |
setCurveDirectionType(int direction)
If the course type is esriCTCurve, defines the direction type of the curve. |
void |
setCurveParameter(int index,
int curveParam)
If the course type is esriCTCurve or esriCTTangentCurve, describes the type of curve paramater that the ith measure text represents. |
void |
setFinishPoint(IPoint finish)
The specified end point of the traverse. |
void |
setFocusToMeasure(int index)
Change the focus to the ith measure text control. |
void |
setIsClosedLoop(boolean closed)
Indicates if the traverse is a closed loop. |
void |
setMeasureSelected(int index,
boolean sel)
Indicates if the text in the ith measure is selected. |
void |
setMeasureText(int index,
String text)
The ith value that defines the course to add. |
void |
setStartPoint(IPoint start)
The specified start point of the traverse. |
void |
setTurnDirection(int direction)
If the course type is esriCTCurve or esriCTTangentCurve, indicates if the curve turns to the left or right. |
void |
setVisible(boolean vis)
Indicates if Traverse Window is visible. |
Method Detail |
---|
void setVisible(boolean vis) throws IOException, AutomationException
vis
- The vis (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isVisible() throws IOException, AutomationException
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IPoint getStartPoint() throws IOException, AutomationException
The starting coordinates of the traverse. The start point must be set before any courses can be added to the traverse with the Add method.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setStartPoint(IPoint start) throws IOException, AutomationException
start
- A reference to a com.esri.arcgis.geometry.IPoint (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.IPoint getFinishPoint() throws IOException, AutomationException
An optional finish point for the traverse. The finish point is only used by the Closure command and Adjust command on the Traverse dialog.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setFinishPoint(IPoint finish) throws IOException, AutomationException
finish
- A reference to a com.esri.arcgis.geometry.IPoint (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getCourseCount() throws IOException, AutomationException
Returns the number of courses in the Course collection. The last course in the Course collection has an index equal to CourseCount - 1.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.ICourse getCourse(int index) throws IOException, AutomationException
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getCourseType() throws IOException, AutomationException
Specifies the type of course that will be added when the Add method is used.
There are four course types;
esriCTDirectionDistance - Add a straight course defined by a direction and a distance.
esriCTAngleDistance - Add a straight course defined by an angle from the previous course and a distance.
esriCTCurve - Add a non-tangent curve course. Any of the following parameters can be used to define the curve; Radius, Arc, Angle or Curve. The TurnDirection specifies that the course will be curving to the left or to the right. The direction of the curve can be specified as a tangent, a radial toward the center point or a chord direction.
esriCTTangentCurve - Add a curve that is tangent to the previous course. Use the same parameters as the esriCTCurve to define the curve.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setCourseType(int type) throws IOException, AutomationException
type
- A com.esri.arcgis.editor.esriCourseType constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isMeasureSelected(int index) throws IOException, AutomationException
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setMeasureSelected(int index, boolean sel) throws IOException, AutomationException
index
- The index (in)sel
- The sel (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.String getMeasureText(int index) throws IOException, AutomationException
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setMeasureText(int index, String text) throws IOException, AutomationException
index
- The index (in)text
- The text (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getMeasureHWND(int index) throws IOException, AutomationException
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getCurveParameter(int index) throws IOException, AutomationException
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setCurveParameter(int index, int curveParam) throws IOException, AutomationException
index
- The index (in)curveParam
- A com.esri.arcgis.editor.esriCurveParameter constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getTurnDirection() throws IOException, AutomationException
The TurnDirection property defines which way a circular arc geometry turns, to the left or right. The property is only used when the course type is either esriCTCurve or esruCTTangentCurve
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setTurnDirection(int direction) throws IOException, AutomationException
direction
- A com.esri.arcgis.editor.esriTurnDirection constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.int getCurveDirectionType() throws IOException, AutomationException
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setCurveDirectionType(int direction) throws IOException, AutomationException
direction
- A com.esri.arcgis.editor.esriCurveDirectionType constant (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isAddEnabled() throws IOException, AutomationException
The Add command on the Traverse Window dialog is enabled under the following conditions;
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void add() throws IOException, AutomationException
Adds a course to the end of the traverse desfined within the TraverseWindow. The course must be specified using the other methods on the ITraverseWindow interface.
The StartPoint needs to exist before any courses can be added.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setFocusToMeasure(int index) throws IOException, AutomationException
Use the SetFocusToMeasure method in conjunction with the MeasureSelected property to select the text within a specific measure control on the Traverse dialog.
The index refers to the measure control to select text in.
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isClosedLoop() throws IOException, AutomationException
The Closed Loop checkbox on the Traverse Window dialog is enabled if both the start and finish point are set.
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void setIsClosedLoop(boolean closed) throws IOException, AutomationException
closed
- The closed (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.boolean isFinishEnabled() throws IOException, AutomationException
The Finish command on the Traverse Window dialog is enabled under the following conditions;
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void remove(int index) throws IOException, AutomationException
Removes the ith course from the traverse window. You cannot remove the 0th course if it is Course Type is either esriCTAngleDistance or esriCTTangentCurve.
index
- The index (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.void finish() 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 |