com.esri.arcgis.editor
Class TraverseWindow

java.lang.Object
  extended by com.esri.arcgis.editor.TraverseWindow
All Implemented Interfaces:
ITraverseWindow, ITraverseWindow2, com.esri.arcgis.interop.RemoteObjRef, IExtension, Serializable

public class TraverseWindow
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, ITraverseWindow, ITraverseWindow2, IExtension

Dialog for creating traverses.

Remarks

The TraverseWindow is used to work with features created with Coordinate Geometry (COGO) descriptions. The TraverseWindow is an editor extension; use IEditor::FindExtension to obtain a reference to it.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface com.esri.arcgis.system.IExtension
IID, IID7f657ec9_dbf1_11d2_9f2f_00c04f6bc69e, xxDummy
 
Constructor Summary
TraverseWindow(Object obj)
          Construct a TraverseWindow using a reference to such an object returned from ArcGIS Engine or Server.
 
Method Summary
 void add()
          Add the course that is defined by the current course parameters.
 void addITraverseWindowEventsListener(ITraverseWindowEvents theListener)
          addITraverseWindowEventsListener.
 boolean equals(Object o)
          Compare this object with another
 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.
 String getName()
          The name of the extension.
 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.
 int hashCode()
          the hashcode for this object
 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 removeITraverseWindowEventsListener(ITraverseWindowEvents theListener)
          removeITraverseWindowEventsListener.
 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.
 void shutdown()
          Shuts down the extension.
 void startup(Object initializationData)
          Starts up the extension with the given initialization data.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef
getJintegraDispatch, release
 

Constructor Detail

TraverseWindow

public TraverseWindow(Object obj)
               throws IOException
Construct a TraverseWindow using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to TraverseWindow.
Casting to this class from the return value of a method will not work, as this class represents an abstract class in ArcObjects.
*
TraverseWindow o = (TraverseWindow)obj; // will not work

TraverseWindow o = new TraverseWindow(obj); // Use this constructor instead
* @param obj an object returned from ArcGIS Engine or Server

Throws:
IOException - if there are interop problems TraverseWindow theTraverseWindow = (TraverseWindow) obj;
Method Detail

equals

public boolean equals(Object o)
Compare this object with another

Overrides:
equals in class Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class Object

addITraverseWindowEventsListener

public void addITraverseWindowEventsListener(ITraverseWindowEvents theListener)
                                      throws IOException
addITraverseWindowEventsListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.editor.ITraverseWindowEvents interface.
Throws:
IOException - If there are communications problems.

removeITraverseWindowEventsListener

public void removeITraverseWindowEventsListener(ITraverseWindowEvents theListener)
                                         throws IOException
removeITraverseWindowEventsListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.editor.ITraverseWindowEvents interface.
Throws:
IOException - If there are communications problems.

setVisible

public void setVisible(boolean vis)
                throws IOException,
                       AutomationException
Indicates if Traverse Window is visible.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setVisible in interface ITraverseWindow
Specified by:
setVisible in interface ITraverseWindow2
Parameters:
vis - The vis (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isVisible

public boolean isVisible()
                  throws IOException,
                         AutomationException
Indicates if Traverse Window is visible.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
isVisible in interface ITraverseWindow
Specified by:
isVisible in interface ITraverseWindow2
Returns:
The vis
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getStartPoint

public IPoint getStartPoint()
                     throws IOException,
                            AutomationException
The specified start point of the traverse.

Remarks

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.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getStartPoint in interface ITraverseWindow
Specified by:
getStartPoint in interface ITraverseWindow2
Returns:
A reference to a com.esri.arcgis.geometry.IPoint
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFinishPoint

public IPoint getFinishPoint()
                      throws IOException,
                             AutomationException
The specified end point of the traverse.

Remarks

An optional finish point for the traverse. The finish point is only used by the Closure command and Adjust command on the Traverse dialog.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getFinishPoint in interface ITraverseWindow
Specified by:
getFinishPoint in interface ITraverseWindow2
Returns:
A reference to a com.esri.arcgis.geometry.IPoint
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCourseCount

public int getCourseCount()
                   throws IOException,
                          AutomationException
The number of courses in the traverse.

Remarks

Returns the number of courses in the Course collection. The last course in the Course collection has an index equal to CourseCount - 1.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getCourseCount in interface ITraverseWindow
Specified by:
getCourseCount in interface ITraverseWindow2
Returns:
The count
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCourse

public ICourse getCourse(int index)
                  throws IOException,
                         AutomationException
A reference to the ith course.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getCourse in interface ITraverseWindow
Specified by:
getCourse in interface ITraverseWindow2
Parameters:
index - The index (in)
Returns:
A reference to a com.esri.arcgis.editor.ICourse
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCourseType

public int getCourseType()
                  throws IOException,
                         AutomationException
The type of the course being added.

Remarks

Specifies the type of course that will be added when the Add method is used. Changing the Type will also switch the controls that are visible on the Traverse dialog. The course is defined by the other methods on the ITraverseWindow interface. 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.

esriCTTangentCurve - Add a curve that is tangent to the previous course.

Notes: A start point must exist before the course can be added. If the course type is esriCTAngleDistance or esriCTTangentCurve, there must be at least one course in the traverse already.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getCourseType in interface ITraverseWindow
Specified by:
getCourseType in interface ITraverseWindow2
Returns:
A com.esri.arcgis.editor.esriCourseType constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setCourseType

public void setCourseType(int type)
                   throws IOException,
                          AutomationException
The type of the course being added.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setCourseType in interface ITraverseWindow
Specified by:
setCourseType in interface ITraverseWindow2
Parameters:
type - A com.esri.arcgis.editor.esriCourseType constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isMeasureSelected

public boolean isMeasureSelected(int index)
                          throws IOException,
                                 AutomationException
Indicates if the text in the ith measure is selected.

Product Availability

Available with ArcGIS Desktop.

Specified by:
isMeasureSelected in interface ITraverseWindow
Specified by:
isMeasureSelected in interface ITraverseWindow2
Parameters:
index - The index (in)
Returns:
The sel
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setMeasureSelected

public void setMeasureSelected(int index,
                               boolean sel)
                        throws IOException,
                               AutomationException
Indicates if the text in the ith measure is selected.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setMeasureSelected in interface ITraverseWindow
Specified by:
setMeasureSelected in interface ITraverseWindow2
Parameters:
index - The index (in)
sel - The sel (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMeasureText

public String getMeasureText(int index)
                      throws IOException,
                             AutomationException
The ith value that defines the course to add.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getMeasureText in interface ITraverseWindow
Specified by:
getMeasureText in interface ITraverseWindow2
Parameters:
index - The index (in)
Returns:
The text
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setMeasureText

public void setMeasureText(int index,
                           String text)
                    throws IOException,
                           AutomationException
The ith value that defines the course to add.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setMeasureText in interface ITraverseWindow
Specified by:
setMeasureText in interface ITraverseWindow2
Parameters:
index - The index (in)
text - The text (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMeasureHWND

public int getMeasureHWND(int index)
                   throws IOException,
                          AutomationException
The handle of the ith measure text control.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getMeasureHWND in interface ITraverseWindow
Specified by:
getMeasureHWND in interface ITraverseWindow2
Parameters:
index - The index (in)
Returns:
The hWND (A COM typedef)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCurveParameter

public int getCurveParameter(int index)
                      throws IOException,
                             AutomationException
If the course type is esriCTCurve or esriCTTangentCurve, describes the type of curve paramater that the ith measure text represents.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getCurveParameter in interface ITraverseWindow
Specified by:
getCurveParameter in interface ITraverseWindow2
Parameters:
index - The index (in)
Returns:
A com.esri.arcgis.editor.esriCurveParameter constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setCurveParameter

public void setCurveParameter(int index,
                              int curveParam)
                       throws IOException,
                              AutomationException
If the course type is esriCTCurve or esriCTTangentCurve, describes the type of curve paramater that the ith measure text represents.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setCurveParameter in interface ITraverseWindow
Specified by:
setCurveParameter in interface ITraverseWindow2
Parameters:
index - The index (in)
curveParam - A com.esri.arcgis.editor.esriCurveParameter constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getTurnDirection

public int getTurnDirection()
                     throws IOException,
                            AutomationException
If the course type is esriCTCurve or esriCTTangentCurve, indicates if the curve turns to the left or right.

Remarks

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

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getTurnDirection in interface ITraverseWindow
Specified by:
getTurnDirection in interface ITraverseWindow2
Returns:
A com.esri.arcgis.editor.esriTurnDirection constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setTurnDirection

public void setTurnDirection(int direction)
                      throws IOException,
                             AutomationException
If the course type is esriCTCurve or esriCTTangentCurve, indicates if the curve turns to the left or right.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setTurnDirection in interface ITraverseWindow
Specified by:
setTurnDirection in interface ITraverseWindow2
Parameters:
direction - A com.esri.arcgis.editor.esriTurnDirection constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCurveDirectionType

public int getCurveDirectionType()
                          throws IOException,
                                 AutomationException
If the course type is esriCTCurve, defines the direction type of the curve.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
getCurveDirectionType in interface ITraverseWindow
Specified by:
getCurveDirectionType in interface ITraverseWindow2
Returns:
A com.esri.arcgis.editor.esriCurveDirectionType constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setCurveDirectionType

public void setCurveDirectionType(int direction)
                           throws IOException,
                                  AutomationException
If the course type is esriCTCurve, defines the direction type of the curve.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setCurveDirectionType in interface ITraverseWindow
Specified by:
setCurveDirectionType in interface ITraverseWindow2
Parameters:
direction - A com.esri.arcgis.editor.esriCurveDirectionType constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isAddEnabled

public boolean isAddEnabled()
                     throws IOException,
                            AutomationException
Indicates if the Add command on the Traverse Window dialog is enabled.

Remarks

The Add command on the Traverse Window dialog is enabled under the following conditions;

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
isAddEnabled in interface ITraverseWindow
Specified by:
isAddEnabled in interface ITraverseWindow2
Returns:
The enabled
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

add

public void add()
         throws IOException,
                AutomationException
Add the course that is defined by the current course parameters.

Remarks

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.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
add in interface ITraverseWindow
Specified by:
add in interface ITraverseWindow2
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setFocusToMeasure

public void setFocusToMeasure(int index)
                       throws IOException,
                              AutomationException
Change the focus to the ith measure text control.

Remarks

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.

Product Availability

Available with ArcGIS Desktop.

Supported Platforms

Windows

Specified by:
setFocusToMeasure in interface ITraverseWindow
Specified by:
setFocusToMeasure in interface ITraverseWindow2
Parameters:
index - The index (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setStartPoint

public void setStartPoint(IPoint start)
                   throws IOException,
                          AutomationException
The specified start point of the traverse.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setStartPoint in interface ITraverseWindow2
Parameters:
start - 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.

setFinishPoint

public void setFinishPoint(IPoint finish)
                    throws IOException,
                           AutomationException
The specified end point of the traverse.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setFinishPoint in interface ITraverseWindow2
Parameters:
finish - 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.

isClosedLoop

public boolean isClosedLoop()
                     throws IOException,
                            AutomationException
Indicates if the traverse is a closed loop.

Remarks

The Closed Loop checkbox on the Traverse Window dialog is enabled if both the start and finish point are set.

Product Availability

Available with ArcGIS Desktop.

Specified by:
isClosedLoop in interface ITraverseWindow2
Returns:
The closed
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setIsClosedLoop

public void setIsClosedLoop(boolean closed)
                     throws IOException,
                            AutomationException
Indicates if the traverse is a closed loop.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setIsClosedLoop in interface ITraverseWindow2
Parameters:
closed - The closed (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isFinishEnabled

public boolean isFinishEnabled()
                        throws IOException,
                               AutomationException
Indicates if the Finish command on the Traverse Window dialog is enabled.

Remarks

The Finish command on the Traverse Window dialog is enabled under the following conditions;

Product Availability

Available with ArcGIS Desktop.

Specified by:
isFinishEnabled in interface ITraverseWindow2
Returns:
The finished
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

remove

public void remove(int index)
            throws IOException,
                   AutomationException
Removes the ith course from the traverse.

Description

Removes the ith course from the traverse window. You cannot remove the 0th course if it is Course Type is either esriCTAngleDistance or esriCTTangentCurve.

Product Availability

Available with ArcGIS Desktop.

Specified by:
remove in interface ITraverseWindow2
Parameters:
index - The index (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

finish

public void finish()
            throws IOException,
                   AutomationException
Finishes the traverse.

Product Availability

Available with ArcGIS Desktop.

Specified by:
finish in interface ITraverseWindow2
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getName

public String getName()
               throws IOException,
                      AutomationException
The name of the extension.

Specified by:
getName in interface IExtension
Returns:
The extensionName
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

startup

public void startup(Object initializationData)
             throws IOException,
                    AutomationException
Starts up the extension with the given initialization data.

Specified by:
startup in interface IExtension
Parameters:
initializationData - A Variant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

shutdown

public void shutdown()
              throws IOException,
                     AutomationException
Shuts down the extension.

Specified by:
shutdown in interface IExtension
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.