|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.uci.ics.jung.visualization.ShapePickSupport
public class ShapePickSupport
ShapePickSupport provides access to Vertices and Edges based on their actual shapes.
Field Summary | |
---|---|
protected HasGraphLayout |
hasGraphLayout
|
protected HasShapeFunctions |
hasShapeFunctions
|
protected LayoutTransformer |
layoutTransformer
|
protected float |
pickSize
|
Constructor Summary | |
---|---|
ShapePickSupport()
Create an instance. |
|
ShapePickSupport(float pickSize)
|
|
ShapePickSupport(HasGraphLayout hasGraphLayout,
LayoutTransformer layoutTransformer,
HasShapeFunctions hasShapeFunctions,
float pickSize)
Create an instance. |
Method Summary | |
---|---|
Edge |
getEdge(double x,
double y)
return an edge whose shape intersects the 'pickArea' footprint of the passed x,y, coordinates. |
LayoutTransformer |
getLayoutTransformer()
|
Vertex |
getVertex(double x,
double y)
Iterates over Vertices, checking to see if x,y is contained in the Vertex's Shape. |
void |
setHasGraphLayout(HasGraphLayout hasGraphLayout)
called by a HasLayout impl (like VisualizationViewer) when this PickSupport impl is added to it. |
void |
setHasShapes(HasShapeFunctions hasShapes)
|
void |
setLayout(Layout layout)
ShapePickSupport gets its layout from its VisualizationViewer, so this
method currently does nothing. |
void |
setLayoutTransformer(LayoutTransformer layoutTransformer)
When this PickSupport is set on a VisualizationViewer, the VisualizationViewer calls this method to pass its layout transformer in |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected HasGraphLayout hasGraphLayout
protected HasShapeFunctions hasShapeFunctions
protected float pickSize
protected LayoutTransformer layoutTransformer
Constructor Detail |
---|
public ShapePickSupport(HasGraphLayout hasGraphLayout, LayoutTransformer layoutTransformer, HasShapeFunctions hasShapeFunctions, float pickSize)
hasGraphLayout
- source of the current layout.hasShapeFunctions
- source of Vertex and Edge shapes.pickSize
- how large to make the pick footprint for line edgespublic ShapePickSupport(float pickSize)
public ShapePickSupport()
Method Detail |
---|
public void setHasGraphLayout(HasGraphLayout hasGraphLayout)
setHasGraphLayout
in interface PickSupport
public void setHasShapes(HasShapeFunctions hasShapes)
hasShapes
- The hasShapes to set.public LayoutTransformer getLayoutTransformer()
public void setLayoutTransformer(LayoutTransformer layoutTransformer)
layoutTransformer
- The layoutTransformer to set.public Vertex getVertex(double x, double y)
getVertex
in interface GraphElementAccessor
GraphElementAccessor.getVertex(double, double)
public Edge getEdge(double x, double y)
getEdge
in interface GraphElementAccessor
public void setLayout(Layout layout)
ShapePickSupport
gets its layout from its VisualizationViewer, so this
method currently does nothing.
setLayout
in interface GraphElementAccessor
GraphElementAccessor.setLayout(edu.uci.ics.jung.visualization.Layout)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |