title: Is there a tool that can count the number of interface references in a project?
body: <p>I have a C# codebase which has evolved over the past year, and I'd like to get some visibility on the number of interface type references vs class type references. Suppose the code is:</p>
  
  <pre><code>namespace Infrastructure {
     public class Foo {
        private ConcreteClass _field1;
        private OtherConcreteClass _field2;
        private IInterface _field3;
  
        public void SomeMethod(ConcreteClass parameter1, IInterface parameter2) {
           _field1 = parameter1;
           _field3 = parameter2;
           OtherConcreteClass newVariable = new OtherConcreteClass();
        }
     }
  }
  </code></pre>
  
  <p>Does anyone know of a tool that would report that there are 2 declared interface references and 4 declared class references in this snippet? I've looked at R#, SourceMonitor, CLOC, and a few others, with no success so far.</p>