I have a rather large open source class that I need to convert from static to non-static.
The reason I need to do this is to make it thread safe; I want one copy of the class per thread.
In general, what are the recommended steps to convert a C# library from static to non-static?
I have upgraded Data Layer from static to no static class. So
1st : remove “static” keyword on class and method
2nd : Add in your old static class a Singleton as well
3rd : Replace in each call for your class by Foo.Instance.DoSomething() instead Foo.DoSomething()
4th : Compile and profit