private static bool IsCode(string line) { var checkedLine = line.Replace(" ", "").Replace("\t", ""); return ((CodeEndings.Any(ending => checkedLine.EndsWith(ending, StringComparison.Ordinal)) || CodeParts.Any(part => checkedLine.Contains(part)) || (checkedLine.Length - checkedLine.Replace("&&", "").Replace("||", "").Length) / 2 >= 3) && !checkedLine.Contains("License")); }
private static bool ContainsCodeParts(string checkedLine) { return(CodeParts.Any(checkedLine.Contains)); }