code: def detectEncodingMeta(self):
          
          buffer = self.rawStream.read(self.numBytesMeta)
          assert isinstance(buffer, bytes)
          parser = EncodingParser(buffer)
          self.rawStream.seek(0)
          encoding = parser.getEncoding()
  
          if encoding is not None and encoding.name in ("utf-16be", "utf-16le"):
              encoding = lookupEncoding("utf-8")
  
          return encoding
docs: Report the encoding declared by the meta element