Package omero.model
Interface SmartShape
-
- All Known Implementing Classes:
SmartEllipseI,SmartLineI,SmartMaskI,SmartPathI,SmartPointI,SmartPolygonI,SmartPolylineI,SmartRectI,SmartTextI
public interface SmartShapeOrthogonal interface hierarchy of types for working with theShapehierarchy.- Since:
- Beta4.1
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceSmartShape.PointCallbackCallback interface passed every point which is within the area of this shape.static classSmartShape.UtilUtility class used as a mixin by all of theSmartShapeimplementations.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidareaPoints(SmartShape.PointCallback action)Calls theSmartShape.PointCallbackwith all of the x/y coordinates which are within the shape.java.awt.ShapeasAwtShape()Converts the currentSmartShapeto aShape.java.util.List<Point>asPoints()Provides some, possibly lossy, bounding polygon of thisSmartShapevia points.voidrandomize(java.util.Random random)Initializes this shape with completely random data.
-
-
-
Method Detail
-
areaPoints
void areaPoints(SmartShape.PointCallback action)
Calls theSmartShape.PointCallbackwith all of the x/y coordinates which are within the shape.- Parameters:
action- the callback to call
-
asAwtShape
java.awt.Shape asAwtShape()
Converts the currentSmartShapeto aShape. This is useful for determining paths and included points.- Returns:
- the AWT shape
-
asPoints
java.util.List<Point> asPoints()
Provides some, possibly lossy, bounding polygon of thisSmartShapevia points.- Returns:
- the bounding polygon
-
randomize
void randomize(java.util.Random random)
Initializes this shape with completely random data.- Parameters:
random- a random number generator
-
-