- File dir = Instance.getReaderDir();
- dir.mkdirs();
- if (!dir.exists()) {
- throw new IOException(
- "Cannote create cache directory for local reader: " + dir);
- }
-
- OutputType text = null;
- OutputType images = null;
-
- try {
- text = OutputType.valueOfNullOkUC(Instance.getUiConfig().getString(
- UiConfig.NON_IMAGES_DOCUMENT_TYPE));
- if (text == null) {
- text = OutputType.HTML;
- }
-
- images = OutputType.valueOfNullOkUC(Instance.getUiConfig()
- .getString(UiConfig.IMAGES_DOCUMENT_TYPE));
- if (images == null) {
- images = OutputType.CBZ;
- }
- } catch (Exception e) {
- UiConfig key = (text == null) ? UiConfig.NON_IMAGES_DOCUMENT_TYPE
- : UiConfig.IMAGES_DOCUMENT_TYPE;
- String value = Instance.getUiConfig().getString(key);
-