Community
Participate
Working Groups
Build Identifier: I have a subsystem that overrides the resolveFilterString(Object, String, IProgressMonitor) method (and the internalResolveFilterString(Object, String, IProgressMonitor)) but these methods are never called when a filter is expanded. Instead, only the resolveFilterStrings(String, IProgressMonitor) method (and the corresponding internal method) is called. This makes it impossible for me to determine which filter was expanded when resolving filter strings. (Or, have I missed something?) I did a bit of investigation and I see that the internalGetChildren(Object, IProgressMonitor) method of SystemViewFilterReferenceAdapter only makes calls to the resolveFilterStrings method that do NOT take in the element being expanded (although the internalGetChildren(...) method DOES have a reference to the filter). Note that the internalGetChildren(...) method of the SystemViewRemoteFileAdapter does call the resolveFilterString method passing in the object being expanded. Reproducible: Always
I think that your custom subsystem should also contribute a custom ISystemViewElementAdapter, as a child of AbstractSystemViewAdapter. When you override public Object[] getChildren(IContextObject element, IProgressMonitor monitor) you can use the IContextObject to understand what filter has been expanded. Could this be sufficient, or am I missing something?
Sorry, I'm a bit confused. The filters I'm expanding in my custom subsystem are RSE filters (created in the performFinish() method of the SystemNewFilterWizard class). Am I really supposed to "override" the ISystemViewElementAdapter associated with RSE filters? (I *have* specified an ISystemViewElementAdapter that subclasses AbstractSystemViewAdapter for my own custom artifacts in the subsystem.) Moreover, the javadoc in the abstract Subsystem class for internalResolveFilterString(Object, String, IProgressMonitor) (line 2979 for me) states: YOU MUST OVERRIDE THIS IF YOU SUPPORT FILTERS! I would expect the method to be called with the appropriate filter that is expanded after I have overridden this method in my subsystem.