November 20, 2008, 04:52:26 pm *
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Deprecated methods  (Read 1807 times)
sunny
Newbie
*
Posts: 1


« on: April 01, 2008, 09:46:00 am »

Hello,
I should looking for deprecated methods in a project. Has anyone an idea how to write a good query?
Thank you very much
Greetings
Sandra
Logged
Mathieu Verbaere
Administrator
Newbie
*****
Posts: 26


« Reply #1 on: April 02, 2008, 01:35:48 pm »

Hi Sandra,

The following query will give you all methods and constructors annotated with @Deprecated:

Code:
from Callable c
where c.getAnAnnotation().getType().hasName("Deprecated")
select c.getDeclaringType(), c

It won't give you, however, elements whose Javadoc contains a tag @deprecated. We are preparing a version of SemmleCode that populates Javadoc, which will allow to spot those too. Thanks for bearing with us.
Logged
Pages: [1]
  Print  
 
Jump to: