private CompletionItem( string?displayText, string?filterText, string?sortText, TextSpan span, ImmutableDictionary <string, string>?properties, ImmutableArray <string> tags, CompletionItemRules?rules, string?displayTextPrefix, string?displayTextSuffix, string?inlineDescription, bool isComplexTextEdit) { DisplayText = displayText ?? ""; DisplayTextPrefix = displayTextPrefix ?? ""; DisplayTextSuffix = displayTextSuffix ?? ""; SortText = sortText ?? DisplayText; InlineDescription = inlineDescription ?? ""; Span = span; Properties = properties ?? ImmutableDictionary <string, string> .Empty; Tags = tags.NullToEmpty(); Rules = rules ?? CompletionItemRules.Default; IsComplexTextEdit = isComplexTextEdit; if (!DisplayText.Equals(filterText ?? "", StringComparison.Ordinal)) { _filterText = filterText; } }
public override bool Equals(object obj) { var other = obj as PythonSuggestedImportAction; if (other == null) { return(false); } return(DisplayText.Equals(other.DisplayText)); }