 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Thierry Monney Guest
|
Posted: Tue Feb 21, 2006 10:03 am Post subject: Find unused local variables, fields and methods |
|
|
Hi all !
Is there a way in JBuilder 2006 to find unused variables, private fields
and private methods ? I know they are displayed in gray in the editor,
but what I need is a way to get somehow a list of them.
In Eclipse, this can be enabled as compiler warnings that appear in the
Problems view (analogous to JBuilder's message pane).
The ultimate purpose would be to go through all of them and remove those
that are not needed (ideally automatically).
Thanks in advance.
Thierry |
|
| Back to top |
|
 |
Doychin Bondzhev Guest
|
Posted: Thu Feb 23, 2006 7:03 am Post subject: Re: Find unused local variables, fields and methods |
|
|
I think Together supports this with it's Audits. You can also check the
audits that are built in the JB can they detect such filed/methods.
Doychin
Thierry Monney wrote:
| Quote: | Hi all !
Is there a way in JBuilder 2006 to find unused variables, private fields
and private methods ? I know they are displayed in gray in the editor,
but what I need is a way to get somehow a list of them.
In Eclipse, this can be enabled as compiler warnings that appear in the
Problems view (analogous to JBuilder's message pane).
The ultimate purpose would be to go through all of them and remove those
that are not needed (ideally automatically).
Thanks in advance.
Thierry |
|
|
| Back to top |
|
 |
Lori M Olson [TeamB] Guest
|
Posted: Thu Feb 23, 2006 6:03 pm Post subject: Re: Find unused local variables, fields and methods |
|
|
Thierry Monney wrote:
| Quote: | Hi all !
Is there a way in JBuilder 2006 to find unused variables, private fields
and private methods ? I know they are displayed in gray in the editor,
but what I need is a way to get somehow a list of them.
In Eclipse, this can be enabled as compiler warnings that appear in the
Problems view (analogous to JBuilder's message pane).
The ultimate purpose would be to go through all of them and remove those
that are not needed (ideally automatically).
Thanks in advance.
Thierry
|
You can download the PMD plugin for JBuilder, and limit the ruleset to
those that check for unused variables, fields, and methods.
http://codecentral.borland.com/Item.aspx?id=23637
http://pmd.sf.net
PMD is more customizable than Code Audits (because you can write your
own rules), and it is free...
--
Regards,
Lori Olson [TeamB]
------------
Save yourself, and everyone else, some time and search the
newsgroups and the FAQ-O-Matic before posting your next
question.
Google Advanced Newsgroup Search
http://www.google.ca/advanced_group_search
Other Newsgroup Searches:
http://www.borland.com/newsgroups/ngsearch.html
Joi Ellis's FAQ-O-Matic:
http://www.visi.com/~gyles19/fom-serve/cache/1.html |
|
| Back to top |
|
 |
Thierry Monney Guest
|
Posted: Mon Feb 27, 2006 9:03 am Post subject: Re: Find unused local variables, fields and methods |
|
|
Doychin Bondzhev wrote:
| Quote: | I think Together supports this with it's Audits. You can also check the
audits that are built in the JB can they detect such filed/methods.
|
Indeed, I didn't see these audits in project properties... Shame on me
for not paying more attention... Anyway thanks for the tip !
| Quote: |
Doychin
Thierry Monney wrote:
Hi all !
Is there a way in JBuilder 2006 to find unused variables, private
fields and private methods ? I know they are displayed in gray in the
editor, but what I need is a way to get somehow a list of them.
In Eclipse, this can be enabled as compiler warnings that appear in
the Problems view (analogous to JBuilder's message pane).
The ultimate purpose would be to go through all of them and remove
those that are not needed (ideally automatically).
Thanks in advance.
Thierry
I think Together supports this with it's Audits. You can also check the
audits that are built in the JB can they detect such filed/methods.
Doychin
Thierry Monney wrote:
Hi all !
Is there a way in JBuilder 2006 to find unused variables, private
fields and private methods ? I know they are displayed in gray in the
editor, but what I need is a way to get somehow a list of them.
In Eclipse, this can be enabled as compiler warnings that appear in
the Problems view (analogous to JBuilder's message pane).
The ultimate purpose would be to go through all of them and remove
those that are not needed (ideally automatically).
Thanks in advance.
Thierry |
|
|
| Back to top |
|
 |
Thierry Monney Guest
|
Posted: Mon Feb 27, 2006 9:03 am Post subject: Re: Find unused local variables, fields and methods |
|
|
Lori M Olson [TeamB] wrote:
| Quote: | Thierry Monney wrote:
Hi all !
Is there a way in JBuilder 2006 to find unused variables, private
fields and private methods ? I know they are displayed in gray in the
editor, but what I need is a way to get somehow a list of them.
In Eclipse, this can be enabled as compiler warnings that appear in
the Problems view (analogous to JBuilder's message pane).
The ultimate purpose would be to go through all of them and remove
those that are not needed (ideally automatically).
Thanks in advance.
Thierry
You can download the PMD plugin for JBuilder, and limit the ruleset to
those that check for unused variables, fields, and methods.
http://codecentral.borland.com/Item.aspx?id=23637
http://pmd.sf.net
PMD is more customizable than Code Audits (because you can write your
own rules), and it is free...
Seems promising, I will give it a shot. Thanks for pointing it out ! |
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|