コード例 #1
0
 public override int GetHashCode()
 {
     return(MoveFrom.GetHashCode() ^ SetMark.GetHashCode()
            ^ BodyFilter.GetHashCode() ^ NameFilter.GetHashCode()
            ^ SearchBoth.GetHashCode() ^ SearchUrl.GetHashCode()
            ^ UseRegex.GetHashCode() ^ ExBodyFilter.GetHashCode()
            ^ ExNameFilter.GetHashCode() ^ ExSearchBoth.GetHashCode()
            ^ ExSearchUrl.GetHashCode() ^ ExUseRegex.GetHashCode()
            ^ IsRt.GetHashCode() ^ Source.GetHashCode()
            ^ IsExRt.GetHashCode() ^ ExSource.GetHashCode()
            ^ UseLambda.GetHashCode() ^ ExUseLambda.GetHashCode());
 }
コード例 #2
0
ファイル: SearchMetadata.cs プロジェクト: dakre/TailBlazer
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = Position;
         hashCode = (hashCode * 397) ^ (SearchText != null ? SearchText.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ Filter.GetHashCode();
         hashCode = (hashCode * 397) ^ Highlight.GetHashCode();
         hashCode = (hashCode * 397) ^ UseRegex.GetHashCode();
         hashCode = (hashCode * 397) ^ IgnoreCase.GetHashCode();
         return(hashCode);
     }
 }
コード例 #3
0
 public bool Equals(FileSetting other)
 {
     return
         (Name.Equals(other.name) &&
          SheetIndex.Equals(other.SheetIndex) &&
          SheetName.Equals(other.SheetName) &&
          IsStartupSheet.Equals(other.IsStartupSheet) &&
          ColumnHeaderIndex.Equals(other.ColumnHeaderIndex) &&
          RowHeaderIndex.Equals(other.RowHeaderIndex) &&
          RowHeaderName.Equals(other.RowHeaderName) &&
          ExactMatch.Equals(other.ExactMatch) &&
          UseRegex.Equals(other.UseRegex) &&
          MaxRowHeaderWidth.Equals(other.MaxRowHeaderWidth));
 }
コード例 #4
0
ファイル: SearchMetadata.cs プロジェクト: ycccq/TailBlazer
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = Position;
         hashCode = (hashCode * 397) ^ (SearchText?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ Filter.GetHashCode();
         hashCode = (hashCode * 397) ^ Highlight.GetHashCode();
         hashCode = (hashCode * 397) ^ UseRegex.GetHashCode();
         hashCode = (hashCode * 397) ^ IgnoreCase.GetHashCode();
         hashCode = (hashCode * 397) ^ (HighlightHue?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ (IconKind?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ IsGlobal.GetHashCode();
         hashCode = (hashCode * 397) ^ IsExclusion.GetHashCode();
         return(hashCode);
     }
 }
コード例 #5
0
        public override string ToString()
        {
            StringBuilder builder = new StringBuilder();

            builder.AppendLine("Exclusions:");
            foreach (CheckBoxModel exclusion in mExclusions)
            {
                builder.AppendLine(String.Format("\t{0}: {1}", exclusion.Text, exclusion.Checked.ToString()));
            }
            builder.AppendLine("Pattern: " + Pattern);
            builder.AppendLine("Scope: " + Scope);
            builder.AppendLine("Search Dir: " + SearchDirectory);
            builder.AppendLine("Ignore Case: " + IgnoreCase.ToString());
            builder.AppendLine("UseRegex: " + UseRegex.ToString());
            builder.AppendLine("Search Subdirectories: " + SearchSubdirectories.ToString());
            builder.AppendLine("Whole Word: " + WholeWord.ToString());
            builder.AppendLine("Sort By File: " + SortByFile.ToString());
            builder.AppendLine("File Name Search: " + FileNameSearch.ToString());
            return(builder.ToString());
        }
コード例 #6
0
ファイル: Measurements.cs プロジェクト: xj0229/gsf
        /// <summary>
        /// Saves advanced find settings to isolated storage.
        /// </summary>
        public void SaveSettings()
        {
            string searchCategories = string.Empty;

            if (SearchCategories.Any(category => category.Selected))
            {
                searchCategories = SearchCategories
                                   .Where(category => category.Selected)
                                   .Select(category => category.Name)
                                   .Aggregate((str1, str2) => str1 + "," + str2);
            }

            IsolatedStorageManager.WriteToIsolatedStorage("MeasurementSearchText", SearchText);
            IsolatedStorageManager.WriteToIsolatedStorage("MeasurementSearchIgnoreCase", IgnoreCase.ToString());
            IsolatedStorageManager.WriteToIsolatedStorage("MeasurementSearchUseWildcards", UseWildcards.ToString());
            IsolatedStorageManager.WriteToIsolatedStorage("MeasurementSearchUseRegex", UseRegex.ToString());
            IsolatedStorageManager.WriteToIsolatedStorage("MeasurementSearchCategories", searchCategories);
        }