Package ome.services.roi
Class GeomTool
- java.lang.Object
-
- ome.services.roi.GeomTool
-
public class GeomTool extends java.lang.Object
Strategy for handling the conversion betweenshapes
and database-specific geometries.- Since:
- Beta4.1
-
-
Field Summary
Fields Modifier and Type Field Description protected PixelData
data
protected ome.services.util.Executor
ex
protected ome.tools.hibernate.SessionFactory
factory
protected java.util.concurrent.atomic.AtomicBoolean
hasShapes
protected org.slf4j.Logger
log
protected ome.util.SqlAction
sql
protected java.lang.String
uuid
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
dbPath(Shape shape)
java.lang.Object
discriminator(java.lang.String string)
Maps from multiple possible user-provided names of shapes (e.g.Ellipse
ellipse(double x, double y, double radiusx, double radiusy)
Ellipse
ellipse(double x, double y, double radiusx, double radiusy, int t, int z)
ShapePoints
getPoints(long shapeId, org.hibernate.Session session)
RoiStats
getStats(java.util.List<java.lang.Long> shapeIds)
ShapeStats[]
getStatsRestricted(java.util.List<java.lang.Long> shapeIds, int zForUnattached, int tForUnattached, int[] channels)
Line
ln(double x1, double y1, double x2, double y2)
Point
pt(double x, double y)
java.util.List<Shape>
random(int count)
Rectangle
rect(double x, double y, double w, double h)
-
-
-
Field Detail
-
log
protected org.slf4j.Logger log
-
hasShapes
protected final java.util.concurrent.atomic.AtomicBoolean hasShapes
-
sql
protected final ome.util.SqlAction sql
-
factory
protected final ome.tools.hibernate.SessionFactory factory
-
data
protected final PixelData data
-
ex
protected final ome.services.util.Executor ex
-
uuid
protected final java.lang.String uuid
-
-
Method Detail
-
random
public java.util.List<Shape> random(int count)
-
ln
public Line ln(double x1, double y1, double x2, double y2)
-
rect
public Rectangle rect(double x, double y, double w, double h)
-
pt
public Point pt(double x, double y)
-
ellipse
public Ellipse ellipse(double x, double y, double radiusx, double radiusy)
-
ellipse
public Ellipse ellipse(double x, double y, double radiusx, double radiusy, int t, int z)
-
dbPath
public java.lang.String dbPath(Shape shape)
-
getPoints
public ShapePoints getPoints(long shapeId, org.hibernate.Session session)
-
getStats
public RoiStats getStats(java.util.List<java.lang.Long> shapeIds)
-
getStatsRestricted
public ShapeStats[] getStatsRestricted(java.util.List<java.lang.Long> shapeIds, int zForUnattached, int tForUnattached, int[] channels)
-
discriminator
public java.lang.Object discriminator(java.lang.String string)
Maps from multiple possible user-provided names of shapes (e.g. "::omero::model::Text", "Text", "TextI", "omero.model.TextI", "ome.model.roi.Text", ...) to the definitive database discriminator.- Parameters:
string
- The string to check.- Returns:
- See above.
-
-