+ if (!yaz_matchstr(fromcode, "UTF8"))
+ {
+ cd->read_handle = yaz_read_UTF8;
+ cd->init_handle = yaz_init_UTF8;
+ }
+ else if (!yaz_matchstr(fromcode, "ISO88591"))
+ cd->read_handle = yaz_read_ISO8859_1;
+ else if (!yaz_matchstr(fromcode, "UCS4"))
+ cd->read_handle = yaz_read_UCS4;
+ else if (!yaz_matchstr(fromcode, "UCS4LE"))
+ cd->read_handle = yaz_read_UCS4LE;
+
+ if (!yaz_matchstr(tocode, "UTF8"))
+ cd->write_handle = yaz_write_UTF8;
+ else if (!yaz_matchstr(tocode, "ISO88591"))
+ cd->write_handle = yaz_write_ISO8859_1;
+ else if (!yaz_matchstr (tocode, "UCS4"))
+ cd->write_handle = yaz_write_UCS4;
+ else if (!yaz_matchstr(tocode, "UCS4LE"))
+ cd->write_handle = yaz_write_UCS4LE;