Modify ResourceMonitoringFilter to first look at returned type to find t...

...he IResource.