@Test public void testContains() throws Exception { Content content = new TestContent(); content.setMinWidth(50); content.setMinHeight(20); assertTrue(content.contains(new Point(0,0))); assertTrue(content.contains(new Point(49,19))); assertTrue(content.contains(new Point(30,10))); assertTrue(content.contains(new Point(1,1))); assertTrue(content.contains(new Point(49,0))); assertFalse(content.contains(new Point(50,20))); assertFalse(content.contains(new Point(-1,0))); assertFalse(content.contains(new Point(100,100))); }
public boolean contains(Point2D point) { return getBounds().contains(point); }
Content { public boolean contains(Point2D point) { return getBounds().contains(point); } }
Content { public boolean contains(Point2D point) { return getBounds().contains(point); }  }
Content { public boolean contains(Point2D point) { return getBounds().contains(point); }  boolean contains(Point2D point); abstract void draw(Graphics2D graphics); final void draw(Graphics2D graphics, Point2D offset); final Rectangle2D getBounds(); Rectangle2D getMinimalBounds(); final double getX(); final double getY(); final double getWidth(); final double getHeight(); void setMinWidth(double minWidth); void setMinHeight(double minHeight); final void refresh(); }
Content { public boolean contains(Point2D point) { return getBounds().contains(point); }  boolean contains(Point2D point); abstract void draw(Graphics2D graphics); final void draw(Graphics2D graphics, Point2D offset); final Rectangle2D getBounds(); Rectangle2D getMinimalBounds(); final double getX(); final double getY(); final double getWidth(); final double getHeight(); void setMinWidth(double minWidth); void setMinHeight(double minHeight); final void refresh();  }