Closed Kaplas80 closed 3 years ago
This PR allows using a Func to define the filter in NodeFactory.FromDirectory methods.
Func
NodeFactory.FromDirectory
This way, the users can define more precisely the files to add to the container.
On the other side, this method will be slower than wildcard filters because it first enumerates all files and, later, filters them.
Get files using a regular expression:
Node node = NodeFactory.FromDirectory(tempDir, x => Regex.IsMatch(x, @"file\d\.(txt|bin)$"));
Description
This PR allows using a
Func
to define the filter inNodeFactory.FromDirectory
methods.This way, the users can define more precisely the files to add to the container.
On the other side, this method will be slower than wildcard filters because it first enumerates all files and, later, filters them.
Example
Get files using a regular expression: