RhSolutions-AddIn/RhSolutions.AddIn/Tools/ReaderWriterTool.cs

16 lines
426 B
C#
Raw Normal View History

2024-11-09 22:59:46 +03:00
namespace RhSolutions.Tools;
internal abstract class ReaderWriterTool: IDisposable
{
protected IReader _reader;
protected IWriter _writer;
protected ReaderFactory _readerFactory = RhSolutionsAddIn.ServiceProvider.GetService<ReaderFactory>();
protected WriterFactory _writerFactory = RhSolutionsAddIn.ServiceProvider.GetService<WriterFactory>();
public void Dispose()
{
_reader?.Dispose();
_writer?.Dispose();
}
}