Add case-insensitive matching to file path match

This commit is contained in:
Matt Nadareski
2024-11-24 23:54:41 -05:00
parent cdf2dd6589
commit bed920b97c

View File

@@ -11,7 +11,8 @@ namespace SabreTools.Matching.Paths
/// Constructor
/// </summary>
/// <param name="needle">String representing the search</param>
public FilePathMatch(string needle)
: base($"{Path.DirectorySeparatorChar}{needle}", false, true) { }
/// <param name="matchCase">True to match exact casing, false otherwise</param>
public FilePathMatch(string needle, bool matchCase = false)
: base($"{Path.DirectorySeparatorChar}{needle}", matchCase, true) { }
}
}