SceneGraph.
| 9 | * SceneGraph. |
| 10 | */ |
| 11 | public class SceneGraph implements Drawable { |
| 12 | /** The shapes. */ |
| 13 | ArrayList<Shape> shapes = new ArrayList<>(); |
| 14 | |
| 15 | /** |
| 16 | * Adds the shape. |
| 17 | * |
| 18 | * @param shape |
| 19 | * the shape |
| 20 | */ |
| 21 | public void addShape(final Shape shape) { |
| 22 | shapes.add(shape); |
| 23 | } |
| 24 | |
| 25 | /** |
| 26 | * Draw. |
| 27 | * |
| 28 | * @param g |
| 29 | * the g |
| 30 | */ |
| 31 | /* (non-Javadoc) |
| 32 | * @see com.xyz.fig.Drawable#draw(java.awt.Graphics2D) |
| 33 | */ |
| 34 | @Override |
| 35 | public void draw(final Graphics2D g) { |
| 36 | for (final Shape shape : shapes) { |
| 37 | shape.draw(g); |
| 38 | } |
| 39 | } |
| 40 | } |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…