Пример #1
0
        public static ImmutableArray <TaggedText> ToTaggedText(this IEnumerable <SymbolDisplayPart> displayParts)
        {
            if (displayParts == null)
            {
                return(ImmutableArray <TaggedText> .Empty);
            }

            return(displayParts.Select(d =>
                                       new TaggedText(SymbolDisplayPartKindTags.GetTag(d.Kind), d.ToString())).ToImmutableArray());
        }
Пример #2
0
        public static ImmutableArray <TaggedText> ToTaggedText(this IEnumerable <SymbolDisplayPart> displayParts, TaggedTextStyle style)
        {
            if (displayParts == null)
            {
                return(ImmutableArray <TaggedText> .Empty);
            }

            return(displayParts.SelectAsArray(d =>
                                              new TaggedText(
                                                  SymbolDisplayPartKindTags.GetTag(d.Kind),
                                                  d.ToString(),
                                                  style,
                                                  GetNavigationTarget(d.Symbol),
                                                  GetNavigationHint(d.Symbol))));