Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 05-29-2008, 08:29 AM
Member
 
Join Date: Apr 2008
Posts: 12
Pooja Deshpande is on a distinguished road
how to find if the code contains deprecated API?
Hi All,

our team has been assigned to develop a Java code, which parses another .java file and identifies if it contains any deprecated API.

any pointers how to identify this?

thanks in advance!
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 05-29-2008, 08:58 AM
Member
 
Join Date: May 2008
Posts: 1
bercolax@gmail.com is on a distinguished road
When you compile the code using -Xlint:deprecation it will list out the deprecated APIs.
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 05-29-2008, 09:17 AM
Member
 
Join Date: Apr 2008
Posts: 12
Pooja Deshpande is on a distinguished road
but this option can be checked from command prompt right? but in case I want to check it in the code itself, something like, I have a code snippet which takes input as a .java file and gives the output as "no of deprecated api's used in this file are: ", how can this be done?
Bookmark Post in Technorati
Reply With Quote
  #4 (permalink)  
Old 05-29-2008, 10:12 AM
Eranga's Avatar
Moderator
 
Join Date: Jul 2007
Location: Colombo, Sri Lanka
Posts: 3,039
Eranga has a spectacular aura aboutEranga has a spectacular aura about
Send a message via Yahoo to Eranga
The way I know is compile the class using above command given on post #2. Can't we pass them as arguments to the application and process it.
__________________
Use an appropriate Subject. "Help, urgent!" isn't one.
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

Has someone helped you? Then you can
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
their helpful post.

Want to make your IDE the best?
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
(Close on September 4, 2008)

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
I need help with a deprecated program mikau New To Java 0 02-13-2008 10:34 AM
getYear deprecated method ravian New To Java 1 01-28-2008 11:35 AM
Using Deprecated Methods ravian New To Java 3 11-23-2007 08:58 PM
method size is deprecated oregon New To Java 4 08-05-2007 06:59 PM
Generating Code Automatically Using Custom code Template In Eclipse JavaForums Eclipse 1 04-26-2007 04:52 PM


All times are GMT +3. The time now is 02:46 PM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org