Esempio n. 1
0
 public static ITextSerializer <BridgeMessage> DefaultSerializerFactory()
 => TextSerializer.NewAsymmetric(
     new TypeDecoratingSerializer(
         SystemJsonSerializer.Default,
         t => typeof(ReplicatorRequest).IsAssignableFrom(t)),
     new TypeDecoratingSerializer(
         SystemJsonSerializer.Default,
         t => typeof(PublisherReply).IsAssignableFrom(t)
         )).ToTyped <BridgeMessage>();