This is wrong.
Why not use CodesetUtil?