It looks like there may be a concern of type adapter collision if more than one adapter uses the same typeId.
If this is true, I'm wondering if it would be better if it was a String instead.
An easy migration path is to use the hashCode of String typeId to get an int value that could be used otherwise, then recommend that people give each type adapter a unique name.
If my understandings here are wrong, please let me know if this is documented somewhere.
It looks like there may be a concern of type adapter collision if more than one adapter uses the same typeId.
If this is true, I'm wondering if it would be better if it was a String instead.
An easy migration path is to use the hashCode of
String typeId
to get an int value that could be used otherwise, then recommend that people give each type adapter a unique name.If my understandings here are wrong, please let me know if this is documented somewhere.