void ZimCreator::fillHeader(ArticleSource& src) { std::string mainAid = src.getMainPage(); std::string layoutAid = src.getLayoutPage(); log_debug("main aid=" << mainAid << " layout aid=" << layoutAid); header.setMainPage(std::numeric_limits<size_type>::max()); header.setLayoutPage(std::numeric_limits<size_type>::max()); if (!mainAid.empty() || !layoutAid.empty()) { for (DirentsType::const_iterator di = dirents.begin(); di != dirents.end(); ++di) { if (mainAid == di->getAid()) { log_debug("main idx=" << di->getIdx()); header.setMainPage(di->getIdx()); } if (layoutAid == di->getAid()) { log_debug("layout idx=" << di->getIdx()); header.setLayoutPage(di->getIdx()); } } } header.setUuid( src.getUuid() ); header.setArticleCount( dirents.size() ); header.setUrlPtrPos( urlPtrPos() ); header.setMimeListPos( mimeListPos() ); header.setTitleIdxPos( titleIdxPos() ); header.setClusterCount( clusterOffsets.size() ); header.setClusterPtrPos( clusterPtrPos() ); header.setChecksumPos( checksumPos() ); log_debug( "mimeListSize=" << mimeListSize() << " mimeListPos=" << mimeListPos() << " indexPtrSize=" << urlPtrSize() << " indexPtrPos=" << urlPtrPos() << " indexSize=" << indexSize() << " indexPos=" << indexPos() << " clusterPtrSize=" << clusterPtrSize() << " clusterPtrPos=" << clusterPtrPos() << " clusterCount=" << clusterCount() << " articleCount=" << articleCount() << " articleCount=" << dirents.size() << " urlPtrPos=" << header.getUrlPtrPos() << " titleIdxPos=" << header.getTitleIdxPos() << " clusterCount=" << header.getClusterCount() << " clusterPtrPos=" << header.getClusterPtrPos() << " checksumPos=" << checksumPos() ); }
void ClusterControllerWidget::emit_refresh_clusters() { emit refreshClusters(clusterCount()); }