Hi hnai
I got the following answer from the vwnc mailing-list:
BrowserEnvironment new referencesTo: (LiteralBindingReference pathString: List fullName) binding
mc := MethodCollector new. bindingToSearch := OrderedCollection fullyQualifiedReference binding. filter := mc referencesTo: bindingToSearch. result := mc select: filter.
and from john.
You need to ask for references to the binding for the class:
(BrowserEnvironment new referencesTo: (Core bindingFor: #OrderedCollection)) classes
You can use either the #classesAndSelectorsDo: or #methodsDo: instead of #classes if you wish to enumerate the methods. You can also combine the environments to narrow or broaden your query. For example, this returns the classes that have methods that reference both Array and OrderedCollection classes:
((BrowserEnvironment new referencesTo: (Core bindingFor: #OrderedCollection)) & (BrowserEnvironment new referencesTo: (Core bindingFor: #Array))) classes
You can rewrite this as: ((BrowserEnvironment new referencesTo: (Core bindingFor: #OrderedCollection)) referencesTo: (Core bindingFor: #Array)) classes
If you wish to find methods that reference OrderedCollection, but not Array:
((BrowserEnvironment new referencesTo: (Core bindingFor: #OrderedCollection)) & (BrowserEnvironment new referencesTo: (Core bindingFor: #Array)) not)