コード例 #1
0
        public EndsWithPatternMatch(FileChangeCategory category, string match)
        {
            if (!match.StartsWith("*"))
            {
                throw new ArgumentOutOfRangeException("match", "Pattern must start with an '*'");
            }

            _category = category;
            _match    = match;

            _suffix = _match.TrimStart('*');
        }
コード例 #2
0
        public EndsWithPatternMatch(FileChangeCategory category, string match)
        {
            if (!match.StartsWith("*"))
            {
                throw new ArgumentOutOfRangeException("match", "Pattern must start with an '*'");
            }

            _category = category;
            _match = match;

            _suffix = _match.TrimStart('*');
        }
コード例 #3
0
ファイル: FileMatcher.cs プロジェクト: KevM/fubu
        private bool matches(FileChangeCategory category, string file)
        {
            var matchers = _matchers[category];

            return(matchers.Any(x => x.Matches(file)));
        }
コード例 #4
0
ファイル: FileMatcher.cs プロジェクト: KevM/fubu
 public IEnumerable <IFileMatch> MatchersFor(FileChangeCategory category)
 {
     return(_matchers[category]);
 }
コード例 #5
0
 public ExactFileMatch(FileChangeCategory category, string file)
 {
     _category = category;
     _file     = file;
 }
コード例 #6
0
ファイル: ExtensionMatch.cs プロジェクト: DarthFubuMVC/fubu
 public ExtensionMatch(FileChangeCategory category, string extension)
 {
     _category = category;
     _extension = Path.GetExtension(extension);
 }
コード例 #7
0
ファイル: ExactFileMatch.cs プロジェクト: DarthFubuMVC/fubu
 public ExactFileMatch(FileChangeCategory category, string file)
 {
     _category = category;
     _file = file;
 }
コード例 #8
0
ファイル: FileMatcher.cs プロジェクト: DarthFubuMVC/fubu
 public IEnumerable<IFileMatch> MatchersFor(FileChangeCategory category)
 {
     return _matchers[category];
 }
コード例 #9
0
ファイル: FileMatcher.cs プロジェクト: DarthFubuMVC/fubu
 private bool matches(FileChangeCategory category, string file)
 {
     var matchers = _matchers[category];
     return matchers.Any(x => x.Matches(file));
 }
コード例 #10
0
 public ExtensionMatch(FileChangeCategory category, string extension)
 {
     _category  = category;
     _extension = Path.GetExtension(extension);
 }