Forums Register Login

Deprecating?

+Pie Number of slices to send: Send
I have never heard of deprecating...would someone tell me what it means?
+Pie Number of slices to send: Send
"Deprecation" is what Sun does when they come up with a better way of doing something in Java... they leave the old stuff in the API, so that old programs will work, but they warn you when you use it, so that you will know that there are better ( or at least newer ) ways to do what you are trying to do...

-Nate
+Pie Number of slices to send: Send
Then what is all of this about deprecating a method?
+Pie Number of slices to send: Send
Conrad
When a method is deprecated it means that there is another recommended way of doing it. For example, this is the description of suspend form the API:

suspend
public final void suspend()
Deprecated. This method has been deprecated, as it is inherently deadlock-prone. If the target thread holds a lock on the monitor protecting a critical system resource when it is suspended, no thread can access this resource until the target thread is resumed. If the thread that would resume the target thread attempts to lock this monitor prior to calling resume, deadlock results. Such deadlocks typically manifest themselves as "frozen" processes. For more information, see Why are Thread.stop, Thread.suspend and Thread.resume Deprecated?.


Basically it is teling you that, yes, you can use it, but they recommend something else.
Also, it is a warning that, at some point, the deprecated method may no longer be supported.
hope that helps
Dave
[This message has been edited by Dave Vick (edited June 18, 2001).]
+Pie Number of slices to send: Send
 

Originally posted by Conrad Kirby:
I have never heard of deprecating...would someone tell me what it means?


depricated , means that it was firstly used with the older version of the jdk. and currently its use is over. that is
what i have heared.
Did you miss me? Did you miss this tiny ad?
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 789 times.
Similar Threads
Adding methods to DBMain
JAVAC not found ??? I cant compile - help
The evils of the metric system
Elbonian Clock
Enumeration vs Iterator
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 15, 2024 23:29:00.