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 4 of 4

Thread: I need add java library

  1. #1
    Junior Member
    Join Date
    Nov 2012
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default I need add java library

    Hi,
    I create android project with netbeans 7.2
    I copy my java game into adnroid project but all java library don't recognize , Now i want add java library to android package.
    For example:
    import java.awt.Color;
    import java.awt.Dimension;
    import java.awt.Font;
    import java.awt.FontMetrics;
    import java.awt.Graphics;
    import java.awt.Image;
    import java.awt.Toolkit;
    import java.awt.event.ActionEvent;
    import java.awt.event.ActionListener;
    import javax.swing.ImageIcon;
    import javax.swing.Timer;
    Attached Images Attached Images


  2. #2
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: I need add java library

    Android does not support all Java SE classes. You should look at the API doc in Android to see what packages are defined.
    You will have to rewrite the code to work in Android with the Android classes.
    If you don't understand my answer, don't ignore it, ask a question.

  3. #3
    Junior Member
    Join Date
    Nov 2012
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: I need add java library

    Quote Originally Posted by Norm View Post
    Android does not support all Java SE classes. You should look at the API doc in Android to see what packages are defined.
    You will have to rewrite the code to work in Android with the Android classes.
    Now do not know any of the classes

    Please see the attachment on first post.

  4. #4
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,140
    Thanks
    65
    Thanked 2,720 Times in 2,670 Posts

    Default Re: I need add java library

    Here is a link to the Android API doc: Package Index | Android Developers
    Look there to see what packages Android supports.
    If you don't understand my answer, don't ignore it, ask a question.

Similar Threads

  1. About java library
    By prabhat11 in forum What's Wrong With My Code?
    Replies: 8
    Last Post: May 27th, 2013, 07:29 AM
  2. Replies: 0
    Last Post: April 5th, 2013, 10:20 AM
  3. Replies: 0
    Last Post: May 3rd, 2010, 04:42 AM
  4. Replies: 1
    Last Post: October 7th, 2008, 07:35 AM