When you explore a memory snapshot, it’s never easy to find the object you need. A typical application operates millions of objects, which means a memory profiler must offer adequate searching capabilities. Before dotMemory 2017.3, object set views provided only basic string search. Now, you can make your search more efficient by creating complex search patterns based on CamelHumps and special symbols.
As usual, the asterisk (*) wildcard means literally “anything” and can be used in any part of your search pattern. For example, sys.*.data may return
If you want to search only among namespaces, you can do this by adding a period (.) at the end of the pattern. For example, sys.*.data. will return
System.Windows.Data.Binding but not the
Search for arrays
If you want to only see arrays in search results, simply use square brackets, . To find arrays of a specific dimension, use commas inside: for example, str[,,] will return
String[,,]. If you omit the closing bracket, search results will contain arrays with the specified dimension and all higher ones: str[,, may return
String[,,] as well as
The Instances view has a bonus: here you can search by array size or size range.
You can exclude arrays from search results by adding !a anywhere in the pattern.
Search for types with generic type arguments
To only search for types with generic type arguments, use angle brackets <>. Similar to array search, commas inside the brackets define the number of arguments.
If you add !g anywhere in the pattern, all generic type arguments will be excluded from the search scope.
Download ReSharper Ultimate to get the updated dotMemory and try the new object search yourself!