generate_packets.py: Streamline field type selection
Part of #43927. Replace the chain of ifs in RawFieldType.parse with appropriate data structures and lookups/loops.
Note: Doing this properly, it was easier to move it into a separate class, so we basically get the ability to swap out the type hierarchy for free.
Part of #43927. Replace the chain of ifs in RawFieldType.parse with appropriate data structures and lookups/loops.