diff options
| author | Fernando Fernández <ferferga.fer@gmail.com> | 2020-11-19 23:18:25 +0100 |
|---|---|---|
| committer | Fernando Fernández <ferferga.fer@gmail.com> | 2020-11-19 23:18:25 +0100 |
| commit | e21e00cad514159e22ddf99f26a4f8c13e16cc52 (patch) | |
| tree | 993002ddcb4815660de00392a7498b9dbbfa973e /Emby.Naming/Video/CleanStringParser.cs | |
| parent | 2deda0437d32016a0c73158840c9c04bc729b261 (diff) | |
| parent | b5ff91c28159695858f24f768b5f6b5b33c0680c (diff) | |
Merge remote-tracking branch 'upstream/master' into no-scaling
Diffstat (limited to 'Emby.Naming/Video/CleanStringParser.cs')
| -rw-r--r-- | Emby.Naming/Video/CleanStringParser.cs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/Emby.Naming/Video/CleanStringParser.cs b/Emby.Naming/Video/CleanStringParser.cs index 3f584d584..09a0cd189 100644 --- a/Emby.Naming/Video/CleanStringParser.cs +++ b/Emby.Naming/Video/CleanStringParser.cs @@ -1,6 +1,3 @@ -#pragma warning disable CS1591 -#nullable enable - using System; using System.Collections.Generic; using System.Text.RegularExpressions; @@ -12,6 +9,13 @@ namespace Emby.Naming.Video /// </summary> public static class CleanStringParser { + /// <summary> + /// Attempts to extract clean name with regular expressions. + /// </summary> + /// <param name="name">Name of file.</param> + /// <param name="expressions">List of regex to parse name and year from.</param> + /// <param name="newName">Parsing result string.</param> + /// <returns>True if parsing was successful.</returns> public static bool TryClean(string name, IReadOnlyList<Regex> expressions, out ReadOnlySpan<char> newName) { var len = expressions.Count; |
