probably think of it this way, adding a new intermediate pre-forward to the original. But the data is not right after transcoding.
after performing a series of operations on a string of data, it is roughly as follows
(1)---------------
String pwdString = new String(byteUtf8,"ISO8859-1");
(2)---------------
byte[] gg = pwdString.getBytes("GBK");
(3)---------------
String ggg = new String(gg,"GBK");
(4)---------------
String s4 = new String(ggg.getBytes("GBK"),"ISO8859-1");
:7D2513D2BF374287
:7D25133F3F37423F
ISO8859-1 seems to have lost data after being transferred to GBK. However, if there is no problem with the UTF-8 used in the interaction between the two steps, and then go back to the original data, it is the same as follows
(1)---------------
String pwdString = new String(byteUtf8,"ISO8859-1");
(2)---------------
byte[] gg = pwdString.getBytes("UTF-8");
(3)---------------
String ggg = new String(gg,"UTF-8");
(4)---------------
String s4 = new String(ggg.getBytes("ISO8859-1"),"ISO8859-1");
:7D2513D2BF374287
:7D2513D2BF374287