MCPcopy Create free account
hub / github.com/codestation/qcma / getObjectSize

Method getObjectSize

common/sqlitedb.cpp:988–1003  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

986}
987
988qint64 SQLiteDB::getObjectSize(int ohfi)
989{
990 if(ohfi < OHFI_BASE_VALUE) {
991 return getChildenTotalSize(ohfi);
992 }
993
994 QSqlQuery query;
995 query.prepare("SELECT size FROM sources WHERE object_id = :object_id");
996 query.bindValue(0, ohfi);
997 if(!query.exec() || !query.next()) {
998 qDebug() << query.lastError();
999 return -1;
1000 } else {
1001 return query.value(0).toInt();
1002 }
1003}
1004
1005int SQLiteDB::getPathId(const char *name, int ohfi)
1006{

Callers

nothing calls this directly

Calls 1

valueMethod · 0.80

Tested by

no test coverage detected