You have CodesetUtil.
https://github.com/opf/openproject/blob/release/3.0.0pre44/lib/redmine/codeset_util.rb#L88