Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 3 of 3

Thread: Do I have to download a package and place it in my C:/ before importing it?

  1. #1
    Junior Member
    Join Date
    Aug 2013
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Do I have to download a package and place it in my C:/ before importing it?

    Hi Javaprogrammers,

    I am trying to test out an exercise in my beginner's book, Big Java. They have an example where they import javax.swing.Jframe and other class such as RectangleViewer. I also want to import java.awt.Graphics.... as well as the Rectangle, and the Graphics2D

    Are these in the preexisting packages? Or do I have to find awt online and download it and place it in the java folder or something? Thanks for any pointers in advance.

    Sincerely,
    Rosalind


  2. #2
    Forum VIP
    Join Date
    Jul 2010
    Posts
    1,676
    Thanks
    25
    Thanked 329 Times in 305 Posts

    Default Re: Do I have to download a package and place it in my C:/ before importing it?

    These ones are preexisting. If the package starts with java or javax, it is *usually* a package already built-in. That is not necessarily *always* the case, since 3rd party developers could start their package with java or javax, but I have never personally seen anyone do that.
    NOTE TO NEW PEOPLE LOOKING FOR HELP ON FORUM:

    When asking for help, please follow these guidelines to receive better and more prompt help:
    1. Put your code in Java Tags. To do this, put [highlight=java] before your code and [/highlight] after your code.
    2. Give full details of errors and provide us with as much information about the situation as possible.
    3. Give us an example of what the output should look like when done correctly.

    Join the Airline Management Simulation Game to manage your own airline against other users in a virtual recreation of the United States Airline Industry. For more details, visit: http://airlinegame.orgfree.com/

  3. #3
    Super Moderator
    Join Date
    Jun 2013
    Location
    So. Maryland, USA
    Posts
    5,517
    My Mood
    Mellow
    Thanks
    215
    Thanked 698 Times in 680 Posts

    Default Re: Do I have to download a package and place it in my C:/ before importing it?

    You sometimes hear the term "Java Core API" or "Java SE", SE = Standard Edition, to describe the libraries or packages that come included with Java's SDK. If you look at the main API page (the link happens to be to Java 7), you can scroll through all of the included packages in the upper left portion of the page, select one (like javax.swing for example), and then see the classes included in that package in the bottom left portion of the page, including JFrame (which you listed incorrectly - remember that Java is VERY case sensitive). If you scroll through the whole package list, you'll see they all start with either java, javax, or org.

    I doubt you will have to download any 3rd party libraries to do the work in the book you have, although it would be a good lesson to teach you someday.

Similar Threads

  1. Package Importing Help
    By sarwardnj in forum What's Wrong With My Code?
    Replies: 3
    Last Post: March 19th, 2013, 07:32 AM
  2. Replies: 4
    Last Post: November 8th, 2012, 07:55 AM
  3. Replies: 1
    Last Post: August 5th, 2012, 05:01 AM
  4. Simple package problem, package does not exist error
    By Farmer in forum Object Oriented Programming
    Replies: 3
    Last Post: August 23rd, 2011, 11:18 AM
  5. importing packages..
    By chronoz13 in forum Java IDEs
    Replies: 4
    Last Post: November 23rd, 2009, 05:49 PM

Tags for this Thread