I am using IntelliJ IDEA.
How I can know how many methods a class has? Are there any plugins to see metrics concerning the number of methods?
CrazyCoder
405k183 gold badges1k silver badges945 bronze badges
asked Aug 29, 2012 at 22:40
Miuler
4732 gold badges6 silver badges13 bronze badges
1 Answer 1
Try the MetricsReloaded plug-in.
Help | Find Action | Calculate Metrics.
Create a new empty profile with CSO enabled — Class metrics, Class size (operations):
Run the profile, it will show the number of methods per class:
You may also want to enable ISO (Interface size) metric.
answered Aug 29, 2012 at 23:12
CrazyCoder
405k183 gold badges1k silver badges945 bronze badges
Sign up to request clarification or add additional context in comments.
12 Comments
Kimball Robinson
Sorry, but I fail to see a feature in the plugin for counting methods in a class. Where do I look?
Lasitha Benaragama
Just Follow the instructions inside the plugin page. Then go to class matrix tab. then you can see the method count.
retodaredevil
For future reference: Go to help -> find action -> calculate metrics. To add the method count for a specific class, click the "..." to the right of the selector. Then you find "Interface metrics" or "Class metrics" and select what you want. That might help out some people, but for me it was still very buggy. It wasn't saving all the options that I selected and I never could get the "method count" to come up.
Rjak
MetricsReloaded counts lines of code and files. It does not have metrics for method/member/function counting.
CrazyCoder
@Rjak thanks for downvoting without doing any research or reading any comments. MetricsReloaded plug-in does allow to calculate the number of methods.
|