MCPcopy Create free account
hub / github.com/baumgarr/nixnote2 / getAll

Method getAll

sql/notebooktable.cpp:542–554  ·  view source on GitHub ↗

Get a list of all notebooks

Source from the content-addressed store, hash-verified

540
541// Get a list of all notebooks
542qint32 NotebookTable::getAll(QList<qint32> &books) {
543 NSqlQuery query(db);
544 db->lockForRead();
545 query.prepare("select distinct lid from DataStore where key=:key");
546 query.bindValue(":key", NOTEBOOK_GUID);
547 query.exec();
548 while (query.next()) {
549 books.append(query.value(0).toInt());
550 }
551 query.finish();
552 db->unlock();
553 return books.size();
554}
555
556
557

Callers

nothing calls this directly

Calls 6

lockForReadMethod · 0.80
bindValueMethod · 0.80
valueMethod · 0.80
prepareMethod · 0.45
execMethod · 0.45
unlockMethod · 0.45

Tested by

no test coverage detected