uk.ac.starlink.topcat.plot2
Interface Figure


public interface Figure

Defines an area on the graphics surface, including criteria for determining whether a given point is or is not included in it.

Since:
15 Feb 2019
Author:
Mark Taylor

Method Summary
 String createExpression(TableCloud cloud)
          Returns an algebraic (JEL) expression that tests whether a point from a given point cloud is contained within this figure.
 Area getArea()
          Returns a drawable shape representing the area defined by this figure on its plotting surface.
 String getExpression()
          Returns a generic algebraic (JEL-like) expression for determining inclusion in this figure.
 void paintPath(Graphics2D g)
          Paints the path defined by this figure's points.
 

Method Detail

getArea

Area getArea()
Returns a drawable shape representing the area defined by this figure on its plotting surface. The shape does not necessarily extend beyond the plot surface's bounding rectangle, even though the figure may encompass a larger area. Null may be returned if this figure does not represent a non-blank area.

Returns:
figure area, or null

paintPath

void paintPath(Graphics2D g)
Paints the path defined by this figure's points. This may or may not be the actual boundary of the enclosed area, but it should convey to the user the choices they have made by selecting the vertices.

Parameters:
g - destination graphics context

getExpression

String getExpression()
Returns a generic algebraic (JEL-like) expression for determining inclusion in this figure. This should represent symbolic variables (such as X, Y) rather than actually available ones. Null may be returned if this figure does not represent a non-blank area.

Returns:
boolean JEL inclusion expression, or null

createExpression

String createExpression(TableCloud cloud)
Returns an algebraic (JEL) expression that tests whether a point from a given point cloud is contained within this figure. Null may be returned if this figure does not represent a non-blank area.

Parameters:
cloud - the source of the data points
Returns:
boolean JEL inclusion expression, or null


Copyright © 2003-2019 CCLRC: Council for the Central Laboratory of the Research Councils. All Rights Reserved.