Fix interface name
This commit is contained in:
parent
c17771a5d3
commit
6a5038246f
@ -25,7 +25,7 @@ public sealed class RhSolutionsAddIn : IExcelAddIn
|
||||
.AddSingleton<IAddInConfiguration, AddInConfiguration>()
|
||||
.AddSingleton<IDatabaseClient, DatabaseClient>()
|
||||
.AddSingleton<ICurrencyClient, CurrencyClient>()
|
||||
.AddSingleton<ISleevesCaluculator, SleevesCalculator>()
|
||||
.AddSingleton<ISleevesCalculator, SleevesCalculator>()
|
||||
.AddTransient<IFileDialog, FileDialog>();
|
||||
|
||||
Services.AddSingleton<WriterFactory>();
|
||||
|
@ -1,6 +1,6 @@
|
||||
namespace RhSolutions.Services;
|
||||
|
||||
public interface ISleevesCaluculator
|
||||
public interface ISleevesCalculator
|
||||
{
|
||||
public Dictionary<Product, double> CalculateSleeves(Dictionary<Product, double> products);
|
||||
}
|
@ -2,7 +2,7 @@
|
||||
|
||||
namespace RhSolutions.Services;
|
||||
|
||||
public class SleevesCalculator : ISleevesCaluculator
|
||||
public class SleevesCalculator : ISleevesCalculator
|
||||
{
|
||||
private const string doublePattern =
|
||||
@"((?i)равнопроходная|угольник 90|угольник 45|Т-образная|Комплект трубок(?i))(.+?(?<Sleeve>\b16\b|\b20\b|\b25\b|\b32\b|\b40\b|\b50\b|\b63\b))+";
|
||||
|
@ -2,9 +2,9 @@
|
||||
|
||||
internal class SleevesTool : Tool
|
||||
{
|
||||
private readonly ISleevesCaluculator _sleevesCaluculator;
|
||||
private readonly ISleevesCalculator _sleevesCaluculator;
|
||||
|
||||
public SleevesTool(ReaderFactory readerFactory, WriterFactory writerFactory, ISleevesCaluculator sleevesCaluculator) : base(readerFactory, writerFactory)
|
||||
public SleevesTool(ReaderFactory readerFactory, WriterFactory writerFactory, ISleevesCalculator sleevesCaluculator) : base(readerFactory, writerFactory)
|
||||
{
|
||||
_sleevesCaluculator = sleevesCaluculator;
|
||||
}
|
||||
|
@ -4,7 +4,7 @@ internal class ToolFactory
|
||||
{
|
||||
static ReaderFactory readerFactory = RhSolutionsAddIn.ServiceProvider.GetService<ReaderFactory>();
|
||||
static WriterFactory writerFactory = RhSolutionsAddIn.ServiceProvider.GetService<WriterFactory>();
|
||||
static ISleevesCaluculator sleevesCaluculator = RhSolutionsAddIn.ServiceProvider.GetService<ISleevesCaluculator>();
|
||||
static ISleevesCalculator sleevesCaluculator = RhSolutionsAddIn.ServiceProvider.GetService<ISleevesCalculator>();
|
||||
|
||||
public Tool GetTool(string toolName)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user