This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This code is for obtaining values from Enums that exist in an SDK and are obfuscated for some reason. | |
for (errorCode in ErrorCode.values()) { | |
Log.info("ErrorCodes: ${errorCode.name} ${errorCode.getCode()}") | |
} | |
private fun Component.getCode():String { | |
return javaClass.getDeclaredField("value").let { | |
it.isAccessible = true |