I want to created a method that calls a repository class in a using() statement. That class is not currently disposable. Is there anything I should consider before making it implement IDisposable?
i.e.
using(var repo = new RespositoryClass() )
{
//do work
}
You should implement
IDisposableif the class uses unmanaged resources, or initializes other members that implement it. Otherwise, don’t use it if you don’t need it.