easik.sketch.util.graph
Class EntityView

java.lang.Object
  extended by org.jgraph.graph.AbstractCellView
      extended by org.jgraph.graph.VertexView
          extended by easik.sketch.util.graph.EntityView
All Implemented Interfaces:
java.io.Serializable, org.jgraph.graph.CellView

public class EntityView
extends org.jgraph.graph.VertexView

A view class for the entity cell type.

Since:
2006-07-25 Kevin Green
Version:
2006-07-26 Kevin Green
Author:
William Belanger 2006, Kevin Green 2006
See Also:
Serialized Form

Nested Class Summary
static class EntityView.EntityRenderer
          The renderer for the circle vertices.
 
Nested classes/interfaces inherited from class org.jgraph.graph.VertexView
org.jgraph.graph.VertexView.SizeHandle
 
Field Summary
static EntityView.EntityRenderer _renderer
          The renderer for this view
 
Fields inherited from class org.jgraph.graph.VertexView
bounds, defaultBounds, defaultCursors, renderer, xCursors, yCursors
 
Fields inherited from class org.jgraph.graph.AbstractCellView
allAttributes, attributes, cell, cellEditor, childViews, groupBounds, parent
 
Constructor Summary
EntityView()
          Creates a new entity view.
EntityView(java.lang.Object cell)
          Sets the cell that this view will be used to render.
 
Method Summary
 java.awt.geom.Point2D getPerimeterPoint(org.jgraph.graph.EdgeView edge, java.awt.geom.Point2D source, java.awt.geom.Point2D p)
          Overridden method to return the proper perimeter point for edges to use
 org.jgraph.graph.CellViewRenderer getRenderer()
          Returns the current renderer
 
Methods inherited from class org.jgraph.graph.VertexView
getBounds, getCachedBounds, getCenterPoint, getHandle, getPerimeterPoint, setCachedBounds, update
 
Methods inherited from class org.jgraph.graph.AbstractCellView
changeAttributes, childUpdated, createAttributeMap, getAllAttributes, getAttributes, getBounds, getCell, getCellAttributes, getCenterPoint, getChildViews, getDescendantViews, getEditor, getParentView, getRendererComponent, includeInGroupBounds, intersects, isLeaf, mergeAttributes, refresh, removeFromParent, scale, setAttributes, setBounds, setCell, translate, updateGroupBounds
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_renderer

public static transient EntityView.EntityRenderer _renderer
The renderer for this view

Constructor Detail

EntityView

public EntityView()
Creates a new entity view.


EntityView

public EntityView(java.lang.Object cell)
Sets the cell that this view will be used to render.

Parameters:
cell - The cell to be rendered by this view.
Method Detail

getRenderer

public org.jgraph.graph.CellViewRenderer getRenderer()
Returns the current renderer

Overrides:
getRenderer in class org.jgraph.graph.VertexView
Returns:
The current renderer

getPerimeterPoint

public java.awt.geom.Point2D getPerimeterPoint(org.jgraph.graph.EdgeView edge,
                                               java.awt.geom.Point2D source,
                                               java.awt.geom.Point2D p)
Overridden method to return the proper perimeter point for edges to use

Specified by:
getPerimeterPoint in interface org.jgraph.graph.CellView
Overrides:
getPerimeterPoint in class org.jgraph.graph.VertexView
Parameters:
edge - The edge
source - The source of the edge
p - The desitination of the edge
Returns:
The perimeter intersection point