aboutsummaryrefslogtreecommitdiff
path: root/Emby.Naming/Video/CleanStringParser.cs
diff options
context:
space:
mode:
authornyanmisaka <nst799610810@gmail.com>2020-11-20 10:01:17 +0800
committernyanmisaka <nst799610810@gmail.com>2020-11-20 10:01:17 +0800
commitb4598bd71b1e2cab057a73cf5daa5ba88ded6625 (patch)
tree9e4b7bbf35909070ced6d04d1dc7c1f9d22478cd /Emby.Naming/Video/CleanStringParser.cs
parentca33ace3e97a85c01848db072708a4e2cf0b251a (diff)
parent90e4066b12e3b39124f9f4efcb20a0e51499a038 (diff)
Merge remote-tracking branch 'upstream/master' into fmp4-hls
Diffstat (limited to 'Emby.Naming/Video/CleanStringParser.cs')
-rw-r--r--Emby.Naming/Video/CleanStringParser.cs10
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;