refactoringresharperautomated-refactoringresharper-9.0notimplementedexception

ReSharper Replace All Method Implementations with NotImplementedException


I have a huge library of classes I copied and I want to set all methods in all classes to:

throw new NotImplementedException();

Does ReSharper have a way to do this globally over the whole solution?


Solution

  • You can do this using ReSharper's Search with Pattern feature in semi-automatic way, i would say. I'll better attach screenshot.

    enter image description here

    This way you replace all private instance methods in Solution. Then you need to replace all public, protected, internal, same with static and virtual keywords and you'll be there.