예제 #1
0
bool DocPlugin::readMetaInfo(Book &book) const {
	if (!DocMetaInfoReader(book).readMetaInfo()) {
		return false;
	}

	shared_ptr<ZLInputStream> stream = new DocCharStream(book.file(), 50000);
	if (!detectEncodingAndLanguage(book, *stream)) {
		stream = new DocAnsiStream(book.file(), 50000);
		detectLanguage(book, *stream, ZLEncodingConverter::UTF8, true);
	}

	return true;
}
예제 #2
0
bool DocPlugin::readMetaInfo(Book &book) const {
	return DocMetaInfoReader(book).readMetaInfo();
}