Searched refs:xml_data (Results 1 – 1 of 1) sorted by relevance
1864 def _detectEncoding(self, xml_data, isHTML=False): argument1868 if xml_data[:4] == '\x4c\x6f\xa7\x94':1870 xml_data = self._ebcdic_to_ascii(xml_data)1871 elif xml_data[:4] == '\x00\x3c\x00\x3f':1874 xml_data = unicode(xml_data, 'utf-16be').encode('utf-8')1875 elif (len(xml_data) >= 4) and (xml_data[:2] == '\xfe\xff') \1876 and (xml_data[2:4] != '\x00\x00'):1879 xml_data = unicode(xml_data[2:], 'utf-16be').encode('utf-8')1880 elif xml_data[:4] == '\x3c\x00\x3f\x00':1883 xml_data = unicode(xml_data, 'utf-16le').encode('utf-8')[all …]