Is there a way to receive serialized objects of different types from the same websocket? The example shows creating one socket per type, is that best practise?
c
Casey Brooks
09/01/2022, 7:02 PM
You’d have to use polymorphic serialization for that (using sealed classes for this makes it easier to work with). The websocket serializer needs some way of determining which class to deserialize into based on the message contents