Results 1 to 5 of 5
  1. #1
    guru_boy is offline Member
    Join Date
    Apr 2009
    Posts
    7
    Rep Power
    0

    Exclamation deprecated API error

    hi all,

    i m creating an application, which takes address of a person and other information and store it in .dat file.

    whenever i compile file i got following error

    Note: AddressBook.java uses or overrides a deprecated API.
    Note: Recompile with -Xlint:deprecation for details.


    however the project is working fine , i couldn't figure out the reason why
    java is prompting me error for nothing.

  2. #2
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    25

    Default

    Even though your program runs, using a deprecated method is not a good thing as Java has slated that method for possible removal. It's a good idea to find out which method is causing the trouble by compiling your code with the -Xlint:deprecation to find out what method(s) shouldn't be used.

  3. #3
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    19

    Default

    And also, Java doc explain all about he deprecated method alternatives. Once you find the method, refer on with the doc and change the code.

  4. #4
    OrangeDog's Avatar
    OrangeDog is offline Senior Member
    Join Date
    Jan 2009
    Location
    Cambridge, UK
    Posts
    838
    Rep Power
    6

    Default

    That's not an error, that's a note.
    Don't forget to mark threads as [SOLVED] and give reps to helpful posts.
    How To Ask Questions The Smart Way

  5. #5
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    19

Similar Threads

  1. deprecated method.. help!
    By iuna in forum Java Applets
    Replies: 11
    Last Post: 09-08-2008, 08:38 PM
  2. how to find if the code contains deprecated API?
    By Pooja Deshpande in forum Advanced Java
    Replies: 3
    Last Post: 05-29-2008, 09:12 AM
  3. I need help with a deprecated program
    By mikau in forum New To Java
    Replies: 0
    Last Post: 02-13-2008, 09:34 AM
  4. Using Deprecated Methods
    By ravian in forum New To Java
    Replies: 3
    Last Post: 11-23-2007, 07:58 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •