diff options
Diffstat (limited to 'RhSolutions.MLModifiers/DrinkingWaterHeatingFittings/ThreadElbowDoubleWallInternal.cs')
-rw-r--r-- | RhSolutions.MLModifiers/DrinkingWaterHeatingFittings/ThreadElbowDoubleWallInternal.cs | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/RhSolutions.MLModifiers/DrinkingWaterHeatingFittings/ThreadElbowDoubleWallInternal.cs b/RhSolutions.MLModifiers/DrinkingWaterHeatingFittings/ThreadElbowDoubleWallInternal.cs deleted file mode 100644 index aaeca67..0000000 --- a/RhSolutions.MLModifiers/DrinkingWaterHeatingFittings/ThreadElbowDoubleWallInternal.cs +++ /dev/null @@ -1,32 +0,0 @@ -using System.Text.RegularExpressions; - -namespace RhSolutions.MLModifiers.DrinkingWaterHeatingFittings; - -[MLModifierKey("Проточный настенный угольник")] -public class ThreadElbowDoubleWallInternal : DrinkingWaterHeatingFitting -{ - protected override string _title => "Проточный настенный угольник"; - private Regex _type = new(@"([\b\Wу])(?<Type>длин)([\b\w\.\s])"); - - public override bool TryQueryModify(string input, out string output) - { - output = string.Empty; - var diameterMatches = _diameter.Matches(input); - if (diameterMatches.Count == 0) - { - return false; - } - var threadMatch = _thread.Match(input); - if (!threadMatch.Success) - { - return false; - } - var typeMatch = _type.Match(input); - string[] diameters = diameterMatches.Select(x => x.Groups["Diameter"].Value).ToArray(); - string thread = threadMatch.Groups["Thread"].Value; - string type = typeMatch.Success ? "длинный" : "короткий"; - - output = $"{_title} {diameters[0]}/{(diameters.Length > 1 ? diameters[1] : diameters[0])}-Rp {thread} {type}"; - return true; - } -}
\ No newline at end of file |