예제 #1
0
        public override void Write(Utf8JsonWriter writer, Action?value, JsonSerializerOptions options)
        {
            if (value is null)
            {
                writer.WriteNullValue(); return;
            }

            var callbackId = References.AddCallback(value);

            writer.WriteStartObject();
            writer.WriteString("callbackId", callbackId);
            writer.WriteEndObject();
        }