public class ConnectorEvent
extends java.util.EventObject
Modifier and Type | Field and Description |
---|---|
static int |
BOTH_ENDS
This event is concerns both ends of the connector.
|
static int |
CONNECTOR_DRAGGED
Signifies that a connector is dragged some distance
|
static int |
CONNECTOR_DROPPED
Signifies that a connector end is dropped.
|
static int |
CONNECTOR_SNAPPED
Signifies that a connector end is snapped to
a possible target.
|
static int |
CONNECTOR_UNSNAPPED
Signifies that a connector end is unsnapped from
the original site that it was attached to, or
from a possible target.
|
static int |
HEAD_END
This event concerns the head end of the connector.
|
static int |
MIDPOINT
This event is concerns the midpoint of the connector.
|
static int |
TAIL_END
This event concerns the tail end of the connector.
|
Constructor and Description |
---|
ConnectorEvent(int id,
java.lang.Object source,
Figure target,
Connector connector,
int end)
Construct a ConnectorEvent with the given source, target,
connector, and "end" flag.
|
Modifier and Type | Method and Description |
---|---|
Connector |
getConnector()
Return the connector that this event concerns.
|
int |
getEnd()
Return the end of the connector that this
event concerns.
|
int |
getID()
Return the type id for this event.
|
Figure |
getTarget()
Return the target that the connector is snapped to
or unsnapped from.
|
java.lang.String |
toString() |
public static final int CONNECTOR_DRAGGED
public static final int CONNECTOR_DROPPED
public static final int CONNECTOR_SNAPPED
public static final int CONNECTOR_UNSNAPPED
public static final int HEAD_END
getEnd()
,
Constant Field Valuespublic static final int TAIL_END
getEnd()
,
Constant Field Valuespublic static final int BOTH_ENDS
getEnd()
,
Constant Field Valuespublic static final int MIDPOINT
getEnd()
,
Constant Field Valuespublic ConnectorEvent(int id, java.lang.Object source, Figure target, Connector connector, int end)
public Connector getConnector()
public int getEnd()
public int getID()
public Figure getTarget()
public java.lang.String toString()
toString
in class java.util.EventObject