?
Solved

deprecated warning

Posted on 2001-06-18
9
Medium Priority
?
473 Views
Last Modified: 2010-03-31
i have a deprecated warning. Which tells me that my applet uses a deprecated API and to recomplie with deprecation for details. Can someone tell me what i should do. I have a thread in my program that doesn't work. I am using jdk 1.1.8 and netscape 6. Any help would be much appreciated.

Thanks VENETA
0
Comment
Question by:Veneta
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
9 Comments
 
LVL 16

Accepted Solution

by:
imladris earned 200 total points
ID: 6204364
The deprecation warning has nothing to do with your thread not working. It is merely alerting you to the fact that you are using methods that will work now, but may not exist in a future release of Java.
0
 
LVL 92

Expert Comment

by:objects
ID: 6204396
If you use the -deprecation option when compiling it'll tell you what the problem is, and if you the check the javadoc for the deprecated method it will explain the preferred replacement method.
0
 
LVL 3

Expert Comment

by:shyamkumarreddy
ID: 6204772
Hi Veneta


Deprecation means the a method in the current version of java is replaced with a good one. And it is no longer available from the current version. But still can be used to run the program. But in the next or future version may this method be removed. So better as said by object recompile with the -deprecation and it will tell where deprecated methods are there just go the javadoc and refer to the class which says deprecated and know more abt it
and change ur code :)

Regarding your thread if u can post your code we could help u to solve it


Cheers
shyam
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 

Expert Comment

by:theoyaung
ID: 6206694
Here's what Sun has to say about deprecated if you want to hear the authority =)

from http://java.sun.com/products/jdk/1.1/docs/guide/misc/deprecation/deprecation.html#what

===What "Deprecated" means===

You may have heard the term, "self-deprecating humor". That is humor that minimizes your importance. A deprecated class or method is like that. It is no longer important. It is so unimportant, in fact, that it should no longer be used at all, as it will probably cease to exist in the future.

The need for deprecation comes about because, as a class evolves, its API changes. Methods are renamed for consistency. New and better methods are added. Attributes change. But making such changes introduces a problem. You need to keep the old API around until people make the transition to the new one, but you don't want developers to continue programming to the old API.

The ability to mark a class or method as "deprecated" solves the problem. Existing classes that use the old API continue to work, but the compiler can issue a warning when it finds references to deprecated items. Meanwhile, the API comments can warn the user against using the deprecated item and tell the user how to avoid doing so. The @deprecated tag achieves these goals.

Note: "Deprecated" and "depreciated" are not same. "Depreciated" is a financial term that means "lowered value". Although the meanings are similar, classes and methods are deprecated, not depreciated.
0
 

Expert Comment

by:kaspak
ID: 6209394
hi

The deprecation warning has nothing to do with your thread not working. It is merely alerting you to
the fact that you are using methods that will work now, but may not exist in a future release of Java.

kaspak
0
 
LVL 92

Expert Comment

by:objects
ID: 6212471
Not necessarily, the methods in Thread are deprecated not only because they may not exist in the future, but also because they are 'unsafe'.
Though you're probably right that their thread problem is something separate.
0
 
LVL 3

Expert Comment

by:shyamkumarreddy
ID: 6213334
Hi Objects
U r correct. But this thread is one of the class which has unsafe methods. which needs to be replaced for safety.

I don't think anyother class has the same think like thread class


Shyam

0
 
LVL 14

Expert Comment

by:sudhakar_koundinya
ID: 9010004
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:


[split points between objects,shyamkumarreddy and imladris]


Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
sudhakar_koundinya
EE Cleanup Volunteer
---------------------
If you feel that your question was not properly addressed, or that none of the comments received were appropriate answers, please post your concern in THIS thread.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
Suggested Courses
Course of the Month8 days, 14 hours left to enroll

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question