Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 Filter "Find References Results" by e.g. Filename

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
MichaelH Posted - Feb 14 2019 : 07:51:02 AM
The "Find References" feature is very useful, but the ability to further filter down the Results is *very* lacking.

The "find in results" feature only allows to you to filter by some text string, but not e.g. by filename or class.

For example, if I want to find, say, all calls to "ScientificProgress::goBoink()" in my different XScience classes (CalvinScience, HobbesScience, SpiffScience, etc.) I still need to manually wade through all the other calls to that function from (in this context) unreleated classes. Some way to filter the results (e.g. by file and/or classname) would make life (and refactoring those calls) much easier.
3   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Feb 15 2019 : 11:29:45 AM
In this situation, do the Builder classes currently have a common base class? Or do they just share a name and behaviour, without having any common base classes?

If they have a common base class, then you can run the Find References from the base class, and turn On the setting "Display inherited and overridden references" to find the calls that VA is picking up in the base classes.

But if there is currently no common base class at all then this ability won't help you at all.

Am I correct in assuming you are looking at function calls, rather than just declarations and implementations here? I was thinking about a form of text search in the Find References Results window, but if you are trying to filter based on the underlining types of the variables then this isn't going to help.

Are you aware you can clone a Find References Results window? This would allow you to run several different VA Find References, one per class you are interested in, and clone each result into a new tab. Not ideal, but it would be a way of separating out the information that you are looking for, and removing all of the unrelated information.

Another thought, if you want to focus just on a specific file, or a specific project within your solution, you can use the Find References in File command to search just the current file, or change the all projects / just the current project setting in the Find References Results window. I am not sure this will help, but it might help a bit.
MichaelH Posted - Feb 15 2019 : 07:47:27 AM
The ability to filter down to only calls/only construction etc. is very useful, thanks.

Still I'd like to be able to filter e.g. only calls from classes (or files) with a specific name pattern (e.g. *Science).
I can manually remove entries I don't care about (in this particular search) from the list, but a way to apply some kind of filter (e.g. based on class or file name) would make life much easier.

For example:
The classes FooBuilder, BarBuilder, and BazBuilder, as well as FooDestroyer, BarDestroyer, BazDestroyer, FooHolder, BarHolder and BazHolder have calls to Thing::doSomething().

I wish to refactor the *Builder classes, e.g. see if it is possible to extract a common BuilderBase class which might (among other things) handle all calls to Thing::doSomething() that are currently made from FooBuilder, BarBuidler and BazBuilder. As such I do not care (in this context) about any calls NOT originating from one of the *Builder classes. I can manually remove all calls from non-builder classes, but this can get tedious if there are more than just 6 calls that need to be removed.
accord Posted - Feb 14 2019 : 2:16:08 PM
If you right click over the Find References window after VA finished searching, you can filter further. If you disable the filter "Display declarations and definitions" and keep "Display References", only the calls will remain in the list.

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000