1

Possible Duplicate:
why import javax.swing.* why not import java.swing.*

This may seem as a stupid question, but why was the Java Swing Framework(a.k.a Java Foundation Classes) put in the javax package instead of the java package like the Abstract Window Toolkit?

import javax.swing.*

instead of

import java.swing.*

What is the difference between java and javax?

Community
  • 1
  • 1
ApprenticeHacker
  • 20,229
  • 26
  • 99
  • 152

2 Answers2

6

The prefix javax is used for a package of Java standard extension.

stacker
  • 66,311
  • 27
  • 138
  • 208
2

Java swing package was not in the first release of java. It's added latter version of java. So it's an extension for java. X stands for extension

nidhin
  • 6,293
  • 5
  • 32
  • 49