def getInterfaceEncoding(self, spssio):
        """This function returns the current interface encoding.
        ('UTF-8' or 'CODEPAGE') and the specific current codepage (e.g. cp1252)"""
        swapped = dict(zip(self.icodes.values(), self.icodes.keys()))
        interfaceEncoding = swapped[spssio.spssGetInterfaceEncoding()]
        encoding = locale.getpreferredencoding()if interfaceEncoding == "CODEPAGE" else "UTF-8"
        return interfaceEncoding, encoding
This function returns the current interface encoding.
        ('UTF-8' or 'CODEPAGE') and the specific current codepage (e.g. cp1252)
recipes/Python/577650_Python_reader_for_spss_sav_files/recipe-577650.py