Set() public method

public Set ( string text, Status status ) : void
text string
status Status
return void
示例#1
0
文件: Model.cs 项目: speecyy/xrefresh
 public bool PassesGlobalExcludes(string path, MatchReason reason)
 {
     // it must not match any global exclude
     foreach (GlobalExcludeFiltersRow row in GlobalExcludeFilters)
     {
         FileMask wildcard = new FileMask(row.Mask);
         if (wildcard.IsMatch(path))
         {
             reason.Set(row.Mask, MatchReason.Status.Excluded);
             return(false);
         }
     }
     return(true);
 }
示例#2
0
文件: Model.cs 项目: speecyy/xrefresh
        public bool PassesGlobalIncludes(string path, MatchReason reason)
        {
            // it must match at least one global include
            foreach (GlobalIncludeFiltersRow row in GlobalIncludeFilters)
            {
                FileMask wildcard = new FileMask(row.Mask);
                if (wildcard.IsMatch(path))
                {
                    reason.Set(row.Mask, MatchReason.Status.Included);
                    return(true);
                }
            }

            // didn't match any include
            return(false);
        }
示例#3
0
文件: Model.cs 项目: speecyy/xrefresh
            public bool PassesLocalExcludes(string path, MatchReason reason)
            {
                ExcludeFiltersRow[] excludes = GetExcludeFiltersRows();

                // it must not match any global exclude
                foreach (ExcludeFiltersRow exclude in excludes)
                {
                    FileMask wildcard = new FileMask(exclude.Mask);
                    if (wildcard.IsMatch(path))
                    {
                        reason.Set(exclude.Mask, MatchReason.Status.Excluded);
                        return(false);
                    }
                }

                // passed excludes
                return(true);
            }
示例#4
0
文件: Model.cs 项目: speecyy/xrefresh
            public bool PassesLocalIncludes(string path, MatchReason reason)
            {
                IncludeFiltersRow[] includes = GetIncludeFiltersRows();

                // it must match at least one global include
                foreach (IncludeFiltersRow include in includes)
                {
                    FileMask wildcard = new FileMask(include.Mask);
                    if (wildcard.IsMatch(path))
                    {
                        reason.Set(include.Mask, MatchReason.Status.Included);
                        return(true);
                    }
                }

                // didn't match any include
                return(false);
            }
示例#5
0
文件: Model.cs 项目: chzh/xrefresh
            public bool PassesLocalIncludes(string path, MatchReason reason)
            {
                IncludeFiltersRow[] includes = GetIncludeFiltersRows();

                // it must match at least one global include
                foreach (IncludeFiltersRow include in includes)
                {
                    FileMask wildcard = new FileMask(include.Mask);
                    if (wildcard.IsMatch(path))
                    {
                        reason.Set(include.Mask, MatchReason.Status.Included);
                        return true;
                    }
                }

                // didn't match any include
                return false;
            }
示例#6
0
文件: Model.cs 项目: chzh/xrefresh
            public bool PassesLocalExcludes(string path, MatchReason reason)
            {
                ExcludeFiltersRow[] excludes = GetExcludeFiltersRows();

                // it must not match any global exclude
                foreach (ExcludeFiltersRow exclude in excludes)
                {
                    FileMask wildcard = new FileMask(exclude.Mask);
                    if (wildcard.IsMatch(path))
                    {
                        reason.Set(exclude.Mask, MatchReason.Status.Excluded);
                        return false;
                    }
                }

                // passed excludes
                return true;
            }
示例#7
0
文件: Model.cs 项目: chzh/xrefresh
        public bool PassesGlobalIncludes(string path, MatchReason reason)
        {
            // it must match at least one global include
            foreach (GlobalIncludeFiltersRow row in GlobalIncludeFilters)
            {
                FileMask wildcard = new FileMask(row.Mask);
                if (wildcard.IsMatch(path))
                {
                    reason.Set(row.Mask, MatchReason.Status.Included);
                    return true;
                }
            }

            // didn't match any include
            return false;
        }
示例#8
0
文件: Model.cs 项目: chzh/xrefresh
 public bool PassesGlobalExcludes(string path, MatchReason reason)
 {
     // it must not match any global exclude
     foreach (GlobalExcludeFiltersRow row in GlobalExcludeFilters)
     {
         FileMask wildcard = new FileMask(row.Mask);
         if (wildcard.IsMatch(path))
         {
             reason.Set(row.Mask, MatchReason.Status.Excluded);
             return false;
         }
     }
     return true;
 }