Differences in extends JComponent, JFrame, JPanel, & Canvas (mega noob question)

Hi JGO,

I am writing this thread because I have a question about extending JComponent, JPanel JFrame, and Canvas. In many different tutorials, I have noticed authors extending these three different classes in their main class. Each of these’s authors are extending different classes and now it has me wondering which ones I should be extending and why. Do you choose one of these classes depending on what kind of game your going to make? All tutorials that I have read have only been 2D so far. I have read it is important to learn 2D concepts and programming techniques before moving on to 3D. Also I have been learning swing from one of my books, but is it necessary to learn this if I am mainly going to write my own ui components? Should I still learn swing regardless?

If you have experience in this and you don’t mind helping a novice out, then I would sure appreciate your help. I hope this is relatively easy to answer.

Cheers,
Andrew