public static class SmartShape.Util extends Object
SmartShape
implementations. The inheritance hierarchy of Ice-generated objects
doesn't allow for simply subclassing .Constructor and Description |
---|
Util() |
Modifier and Type | Method and Description |
---|---|
static void |
appendDbPoint(StringBuilder sb,
double x,
double y) |
static void |
appendDbPoint(StringBuilder sb,
omero.model.Point p) |
static boolean |
appendSegment(StringBuilder sb,
boolean first,
double x,
double y) |
static void |
appendSvgPoint(StringBuilder sb,
double x,
double y) |
static void |
appendSvgPoint(StringBuilder sb,
omero.model.Point p) |
static boolean |
checkNonNull(List<omero.model.Point> points)
Used from assert statements of the form:
assert Util.checkNonNull(points) : "Null points in " + this;
in all the implementations of
SmartShape.asPoints() . |
static Shape |
parseAwtPath(String str) |
static List<omero.model.Point> |
parsePoints(String str) |
static String |
parsePointsToPath(String str,
boolean close) |
static List<omero.model.Point> |
points(double x,
double y,
double w,
double h)
Returns the four corner points of a rectangle
|
static void |
pointsByBoundingBox(Shape s,
Rectangle2D r,
SmartShape.PointCallback cb) |
static String |
pointsToPath(List<omero.model.Point> points,
boolean close) |
public static boolean checkNonNull(List<omero.model.Point> points)
assert Util.checkNonNull(points) : "Null points in " + this;in all the implementations of
SmartShape.asPoints()
.points
- the pointsNullPointerException
public static void appendDbPoint(StringBuilder sb, omero.model.Point p)
public static void appendDbPoint(StringBuilder sb, double x, double y)
public static void appendSvgPoint(StringBuilder sb, omero.model.Point p)
public static void appendSvgPoint(StringBuilder sb, double x, double y)
public static boolean appendSegment(StringBuilder sb, boolean first, double x, double y)
public static List<omero.model.Point> points(double x, double y, double w, double h)
x
- the top-left corner's x coordinate (the lowest x)y
- the top-left corner's y coordinate (the lowest y)w
- width of the rectangle so that x+w gives the highest xh
- height of the rectange so taht y+h gives the highest ypublic static void pointsByBoundingBox(Shape s, Rectangle2D r, SmartShape.PointCallback cb)
Version: 5.3.3-ice35-b63
Copyright © 2017 The University of Dundee & Open Microscopy Environment. All Rights Reserved.