forName

Looks up a charset by canonical name or any ECI/Java alias ZXing uses. Case-insensitive, and tolerant of - vs _ spelling.

The separator-insensitive fallback matters: CharacterSetECI resolves charsets by its own enum constant name (ISO8859_2, EUC_KR), which is spelled differently from the canonical name (ISO-8859-2, EUC-KR). On the JVM Charset.isSupported accepts both because the JDK registers the underscore forms as aliases; this keeps us equally forgiving even if a generated alias list is ever incomplete.

Returns null if unsupported (matching CharacterSetECI.isCharsetSupported returning false).