コード例 #1
0
        public override bool Accept(IActivityMonitor m, AddedDiff createdDiff)
        {
            var matchingPath = DiffRoot.Paths.FirstOrDefault(path => createdDiff.Path.StartsWith(path));

            if (matchingPath != null)
            {
                m.Debug($"Added file ({createdDiff.Path}) matched with one of the DiffRoot '{DiffRoot.Name}' path: {matchingPath}");
                AddedDiffs.Add(createdDiff);
                return(true);
            }
            m.Debug($"Added file ({createdDiff.Path}) did not match with any of the DiffRoot '{DiffRoot.Name}' paths.");
            return(false);
        }
コード例 #2
0
 public abstract bool Accept(IActivityMonitor m, AddedDiff createdDiff);
コード例 #3
0
 public override bool Accept(IActivityMonitor m, AddedDiff createdDiff)
 {
     AddedDiffs.Add(createdDiff);
     return(true);
 }