def _processPacket(self, packet):
try:<EOL><INDENT>packet_type      = (packet[<NUM_LIT:0>] & <NUM_LIT>) >> <NUM_LIT:4><EOL>packet_flags     = (packet[<NUM_LIT:0>] & <NUM_LIT>)<EOL>packet_type_name = self.packetTypes[packet_type]<EOL><DEDENT>except KeyError as e:<EOL><INDENT>log.error("<STR_LIT>" % packet_type)<EOL>self.transport.abortConnection()<EOL>return<EOL><DEDENT>packetDecoder = getattr(self, "<STR_LIT>" % packet_type_name, None)<EOL>if packetDecoder:<EOL><INDENT>packetDecoder(packet)<EOL><DEDENT>else:<EOL><INDENT>log.error("<STR_LIT>" % packet_type_name)<EOL>self.transport.abortConnection()<EOL>return<EOL><DEDENT>
Generic MQTT packet decoder