ballwar.model.paint
Interface IShapeFactory
- All Known Implementing Classes:
- EllipseShapeFactory, Fish1PolygonFactory, Fish2PolygonFactory, PolygonFactory, RectangleShapeFactory
public interface IShapeFactory
Abstract factory that creates a Shape for use as prototype shapes in
IPaintStrategies. The location of the center of the shape and the
x and y scales can be specified.
Method Summary |
Shape |
makeShape(double x,
double y,
double xScale,
double yScale)
Returns a Shape object centered at (x, y) and with the specified
x and y dimensions. |
makeShape
Shape makeShape(double x,
double y,
double xScale,
double yScale)
- Returns a Shape object centered at (x, y) and with the specified
x and y dimensions.
- Parameters:
x
- x-coordinate of the center of the shapey
- y-coordinate of the center of the shapexScale
- The x-dimension of the shape, usually the x-radius.yScale
- The y-dimension of the shape, usually the y-radius.
- Returns:
- A Shape instance.