Extending the Graphics class in Java
<p>I need to extend the Graphics class in order to <code>@Override</code> some methods including <code>drawRect(int,int,int,int)</code> and <code>drawRoundRect(int,int,int,int,int,int)</code>. 
However, I have no idea how to do that. This is what I've got so far: </p>

<pre><code>  public class myGraphics extends Graphics {
      @Override
      public void drawRect(int x, int y, int width, int height) {
          super.fillRect(x, y, width, height);
          setColor(Color.WHITE);
          super.fillRect(x, y, width-6, height-6);
      }

      @Override
      public void drawRoundRect(int x, int  y, int width, int height, int arcWidth, int arcHeight) {
          super.fillRoundRect(x, y, width, height, arcWidth, arcHeight);
          setColor(Color.WHITE);
          super.fillRoundRect(x, y, width-6, height-6, arcWidth, arcHeight);
        }
    }
</code></pre>

<p>I get an error on class declaration line saying: <code>myGraphics is not abstract and does not override abstract method dispose() in java.awt.Graphics</code>
I also get an error on every line where <code>super.fill..(..)</code> is mentioned saying: <code>abstract method fill..(..) in java.awt.Graphics cannot be accessed directly</code>.
Does anyone have an idea on what can I do?</p>