| 549 | } |
| 550 | |
| 551 | String FileHandler::computeFileHash(const String& filename) |
| 552 | { |
| 553 | QCryptographicHash crypto(QCryptographicHash::Sha1); |
| 554 | QFile file(filename.toQString()); |
| 555 | file.open(QFile::ReadOnly); |
| 556 | while (!file.atEnd()) |
| 557 | { |
| 558 | crypto.addData(file.read(8192)); |
| 559 | } |
| 560 | return String((QString)crypto.result().toHex()); |
| 561 | } |
| 562 | |
| 563 | bool FileHandler::loadFeatures(const String& filename, FeatureMap& map, FileTypes::Type force_type) |
| 564 | { |