Пример #1
0
 public IEnumerable <SqlScript> Filter(
     IEnumerable <SqlScript> sorted,
     HashSet <string> executedScriptNames,
     ScriptNameComparer comparer)
 {
     return(sorted.Where(sqlScript => DefaultScriptFilter.ScriptShouldRun(sqlScript, executedScriptNames, comparer, null, null)));
 }
Пример #2
0
        public IEnumerable <SqlScript> Filter(
            IOrderedEnumerable <SqlScript> sorted,
            IEnumerable <ExecutedSqlScript> executedScripts,
            ScriptNameComparer comparer,
            IHasher hasher)
        {
            var executedScriptsList = executedScripts.ToList();
            var executedScriptNames = new HashSet <string>(executedScriptsList.Select(x => x.Name), comparer);

            return(sorted.Where(sqlScript => DefaultScriptFilter.ScriptShouldRun(sqlScript, executedScriptNames, comparer, executedScriptsList, hasher)));
        }