com.esri.arcgis.editor
Class IntersectionConstructor

java.lang.Object
  extended by com.esri.arcgis.editor.IntersectionConstructor
All Implemented Interfaces:
IShapeConstructor, com.esri.arcgis.interop.RemoteObjRef, Serializable

public class IntersectionConstructor
extends Object
implements com.esri.arcgis.interop.RemoteObjRef, IShapeConstructor

Intersects two line segments to create a new point.

Product Availability

Available with ArcGIS Desktop.

See Also:
Serialized Form

Constructor Summary
IntersectionConstructor()
          Constructs a IntersectionConstructor using ArcGIS Engine.
IntersectionConstructor(Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
IntersectionConstructor theIntersectionConstructor = (IntersectionConstructor) obj;
 
Method Summary
 void activate()
          Prepares a shape constructor to begin receiving events.
 void addPoint(IPoint point, boolean esri_clone, boolean allowUndo)
          Adds a point to the sketch.
 void deactivate()
          Resets a shape constructor.
 boolean equals(Object o)
          Compare this object with another
 IPoint getAnchor()
          The anchor of the sketch.
 double getAngleConstraint()
          The sketch's angular constraint.
static String getClsid()
          getClsid.
 int getConstraint()
          The sketch constraint.
 int getCursor()
          The mouse pointer for this constructor.
 double getDistanceConstraint()
          The sketch's distance constraint.
 String getID()
          Name string identifying this shape constructor.
 IPoint getLocation()
          The current location of the mouse.
 int hashCode()
          the hashcode for this object
 void initialize(IEditor pEditor)
          Initializes a newly constructed shape constructor.
 boolean isActive()
          Indicates whether the constructor is currently active.
 boolean isEnabled()
          Indicates whether the constructor is enabled.
 boolean isStreaming()
          Indicates whether stream mode digitizing is enabled.
 boolean onContextMenu(int x, int y)
          Context menu event occured at the given xy location.
 void onKeyDown(int keyState, int shift)
          Occurs when a key on the keyboard is pressed when this constructor is active.
 void onKeyUp(int keyState, int shift)
          Occurs when a key on the keyboard is released when this constructor is active.
 void onMouseDown(int button, int shift, int x, int y)
          Occurs when a mouse button is pressed when this constructor is active.
 void onMouseMove(int button, int shift, int x, int y)
          Occurs when the mouse is moved when this constructor is active.
 void onMouseUp(int button, int shift, int x, int y)
          Occurs when a mouse button is released when this constructor is active.
 void refresh(int hdc)
          Occurs when a screen display in the application is refreshed.
 void setAngleConstraint(double val)
          The sketch's angular constraint.
 void setConstraint(int constraint)
          The sketch constraint.
 void setDistanceConstraint(double val)
          The sketch's distance constraint.
 void setIsStreaming(boolean isStreaming)
          Indicates whether stream mode digitizing is enabled.
 void sketchModified()
          Called when Sketch is modified.
 
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

IntersectionConstructor

public IntersectionConstructor()
                        throws IOException,
                               UnknownHostException
Constructs a IntersectionConstructor using ArcGIS Engine.

Throws:
IOException - if there are interop problems
UnknownHostException - if there are interop problems

IntersectionConstructor

public IntersectionConstructor(Object obj)
                        throws IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
IntersectionConstructor theIntersectionConstructor = (IntersectionConstructor) obj;

Construct a IntersectionConstructor using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to IntersectionConstructor.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
IOException - if there are interop problems
Method Detail

getClsid

public static String getClsid()
getClsid.


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

initialize

public void initialize(IEditor pEditor)
                throws IOException,
                       AutomationException
Initializes a newly constructed shape constructor.

Product Availability

Available with ArcGIS Desktop.

Specified by:
initialize in interface IShapeConstructor
Parameters:
pEditor - A reference to a com.esri.arcgis.editor.IEditor (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getID

public String getID()
             throws IOException,
                    AutomationException
Name string identifying this shape constructor.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getID in interface IShapeConstructor
Returns:
The iD
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isEnabled

public boolean isEnabled()
                  throws IOException,
                         AutomationException
Indicates whether the constructor is enabled.

Product Availability

Available with ArcGIS Desktop.

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

activate

public void activate()
              throws IOException,
                     AutomationException
Prepares a shape constructor to begin receiving events.

Product Availability

Available with ArcGIS Desktop.

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

deactivate

public void deactivate()
                throws IOException,
                       AutomationException
Resets a shape constructor.

Product Availability

Available with ArcGIS Desktop.

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

isActive

public boolean isActive()
                 throws IOException,
                        AutomationException
Indicates whether the constructor is currently active.

Product Availability

Available with ArcGIS Desktop.

Specified by:
isActive in interface IShapeConstructor
Returns:
The active
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

onMouseDown

public void onMouseDown(int button,
                        int shift,
                        int x,
                        int y)
                 throws IOException,
                        AutomationException
Occurs when a mouse button is pressed when this constructor is active.

Product Availability

Available with ArcGIS Desktop.

Specified by:
onMouseDown in interface IShapeConstructor
Parameters:
button - The button (in)
shift - The shift (in)
x - The x (in)
y - The y (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

onMouseMove

public void onMouseMove(int button,
                        int shift,
                        int x,
                        int y)
                 throws IOException,
                        AutomationException
Occurs when the mouse is moved when this constructor is active.

Product Availability

Available with ArcGIS Desktop.

Specified by:
onMouseMove in interface IShapeConstructor
Parameters:
button - The button (in)
shift - The shift (in)
x - The x (in)
y - The y (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

onMouseUp

public void onMouseUp(int button,
                      int shift,
                      int x,
                      int y)
               throws IOException,
                      AutomationException
Occurs when a mouse button is released when this constructor is active.

Product Availability

Available with ArcGIS Desktop.

Specified by:
onMouseUp in interface IShapeConstructor
Parameters:
button - The button (in)
shift - The shift (in)
x - The x (in)
y - The y (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

onKeyDown

public void onKeyDown(int keyState,
                      int shift)
               throws IOException,
                      AutomationException
Occurs when a key on the keyboard is pressed when this constructor is active.

Product Availability

Available with ArcGIS Desktop.

Specified by:
onKeyDown in interface IShapeConstructor
Parameters:
keyState - The keyState (in)
shift - The shift (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

onKeyUp

public void onKeyUp(int keyState,
                    int shift)
             throws IOException,
                    AutomationException
Occurs when a key on the keyboard is released when this constructor is active.

Product Availability

Available with ArcGIS Desktop.

Specified by:
onKeyUp in interface IShapeConstructor
Parameters:
keyState - The keyState (in)
shift - The shift (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

onContextMenu

public boolean onContextMenu(int x,
                             int y)
                      throws IOException,
                             AutomationException
Context menu event occured at the given xy location.

Product Availability

Available with ArcGIS Desktop.

Specified by:
onContextMenu in interface IShapeConstructor
Parameters:
x - The x (in)
y - The y (in)
Returns:
The handled
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

refresh

public void refresh(int hdc)
             throws IOException,
                    AutomationException
Occurs when a screen display in the application is refreshed.

Product Availability

Available with ArcGIS Desktop.

Specified by:
refresh in interface IShapeConstructor
Parameters:
hdc - The hdc (A COM typedef) (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getCursor

public int getCursor()
              throws IOException,
                     AutomationException
The mouse pointer for this constructor.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getCursor in interface IShapeConstructor
Returns:
The cursor (A COM typedef)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getAnchor

public IPoint getAnchor()
                 throws IOException,
                        AutomationException
The anchor of the sketch.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getAnchor in interface IShapeConstructor
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.

getLocation

public IPoint getLocation()
                   throws IOException,
                          AutomationException
The current location of the mouse.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getLocation in interface IShapeConstructor
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.

getConstraint

public int getConstraint()
                  throws IOException,
                         AutomationException
The sketch constraint.

Product Availability

Available with ArcGIS Desktop.

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

setConstraint

public void setConstraint(int constraint)
                   throws IOException,
                          AutomationException
The sketch constraint.

Product Availability

Available with ArcGIS Desktop.

Specified by:
setConstraint in interface IShapeConstructor
Parameters:
constraint - A com.esri.arcgis.editor.esriSketchConstraint constant (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getAngleConstraint

public double getAngleConstraint()
                          throws IOException,
                                 AutomationException
The sketch's angular constraint.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getAngleConstraint in interface IShapeConstructor
Returns:
The val
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setAngleConstraint

public void setAngleConstraint(double val)
                        throws IOException,
                               AutomationException
The sketch's angular constraint.

Product Availability

Available with ArcGIS Desktop.

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

getDistanceConstraint

public double getDistanceConstraint()
                             throws IOException,
                                    AutomationException
The sketch's distance constraint.

Product Availability

Available with ArcGIS Desktop.

Specified by:
getDistanceConstraint in interface IShapeConstructor
Returns:
The val
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setDistanceConstraint

public void setDistanceConstraint(double val)
                           throws IOException,
                                  AutomationException
The sketch's distance constraint.

Product Availability

Available with ArcGIS Desktop.

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

isStreaming

public boolean isStreaming()
                    throws IOException,
                           AutomationException
Indicates whether stream mode digitizing is enabled.

Product Availability

Available with ArcGIS Desktop.

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

setIsStreaming

public void setIsStreaming(boolean isStreaming)
                    throws IOException,
                           AutomationException
Indicates whether stream mode digitizing is enabled.

Product Availability

Available with ArcGIS Desktop.

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

addPoint

public void addPoint(IPoint point,
                     boolean esri_clone,
                     boolean allowUndo)
              throws IOException,
                     AutomationException
Adds a point to the sketch.

Product Availability

Available with ArcGIS Desktop.

Specified by:
addPoint in interface IShapeConstructor
Parameters:
point - A reference to a com.esri.arcgis.geometry.IPoint (in)
esri_clone - The esri_clone (in)
allowUndo - The allowUndo (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

sketchModified

public void sketchModified()
                    throws IOException,
                           AutomationException
Called when Sketch is modified.

Product Availability

Available with ArcGIS Desktop.

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