Visualization Tools User's Guide
The Snooper allows you to search through a hierarchy of objects for
values satisfying a predicate (a boolean expression). The search is a
depth-limited depth-first search. There are many ways of tuning the
search.
- Press the Search button, opening a (Spy Search)
window.
- In the Search For tab of the (Spy Search) window,
type a one-argument block which answers true when applied to an
object that you are looking for, and false otherwise. If
your block fails on a given argument (e.g., if you call x
accelerator and some x does not respond to
#accelerator), the block is considered to return
false.
- Select the depth of the search by picking a radio button at the bottom of
the window. The depth 2 is selected by default. Depths higher
than 6 are available by selecting the + radio button, then using
the spinner. The search engine is fairly slow, so large depths are not
recommended.
- (Optional) Prune the search. Select the Prune
tab. Fill in the block of code titled Only search under values
which satisfy. This block is a two-argument block, taking (1) the
attribute name being searched, and (2) the value of that attribute.
When the block returns true, the search engine will look beneath that
block. Pruning can speed up the search -- or can slow it down,
because testing values to be pruned (even with a very simple test) is
expensive.
- (Optional) On the Options tab, set the options that you want
for the search.
- If you only want to open the hierarchical structure to show all the items
that you found, but not change the currently selected items, deselect
Select all matching items.
- If you do not want to hide all the items which do not meet your search
criterion, deselect Hide non-matching items.
- If it will suffice to find only one item matching your requirements,
select Stop searching on first match. This can speed
searches up tremendously.
- If you want to see a mediocre kind of progress indicator on the System
Transcript, select Show Progress On Transcript.
- If you don't want to contract the tree before starting the search,
deselect Contract tree before searching.
- If you want to search under just the selected items, instead of the
self item, select Search under Just the Selected
Items.
- If you want to flag the items that were found, select Mark Found
Items with, and then type or select a symbol in the combo box.
- If you are searching a structure with many common sub-objects, select
Don't re-search objects (There is a substantial overhead for
keeping track of which objects have been searched).
- When you are ready to search, press the Search! button.
The Snooper keeps a list of the searches you have performed. If you
want to repeat a search, possibly with modifications:
- Press the Prev button (or Next button) until the
search that you want to redo or modify appears.
- (Optional) Press the Copy button to create a new copy of that
search, so that changes you do will not modify the original one.
- Update the controls as above, and perform your search.
[ Top of Page | Previous Page | Next Page | Table of Contents ]