public static void WriteTagsProperty(this IFastJsonWriter writer, string name, ImmutableArray <string> tags)
 {
     writer.WritePropertyStartArray(name);
     foreach (var tag in tags)
     {
         writer.WriteValue(FastConvert.StringToLowerInvariantString(tag));
     }
     writer.WriteEndArray();
 }
Exemple #2
0
 public static void WriteSymbolDisplayPart(this IFastJsonWriter writer, SymbolDisplayPart part, bool selected)
 {
     writer.WriteStartObject();
     writer.WriteProperty("text", part.ToString());
     writer.WriteProperty("kind", FastConvert.EnumToLowerInvariantString(part.Kind));
     if (selected)
     {
         writer.WriteProperty("selected", true);
     }
     writer.WriteEndObject();
 }
 public static void WriteTaggedText(this IFastJsonWriter writer, TaggedText text, bool selected)
 {
     writer.WriteStartObject();
     writer.WriteProperty("text", text.Text);
     writer.WriteProperty("kind", FastConvert.StringToLowerInvariantString(text.Tag));
     if (selected)
     {
         writer.WriteProperty("selected", true);
     }
     writer.WriteEndObject();
 }