When Not to Use Inheritance

public class Point 
{ 
   public Point(int anX, int aY) { ... } 
   public void translate(int dx, int dy) { ... } 
   private int x; 
   private int y; 
} 

public class Circle extends Point // DON'T 
{ 
   public Circle(Point center, int radius) { ... } 
   public void draw(Graphics g) { ... } 
   private int radius; 
} 


previous | start | next .... [Slide 64] ....