MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / getUpdater

Method getUpdater

lib/QSimpleUpdater/src/QSimpleUpdater.cpp:490–505  ·  view source on GitHub ↗

* @brief Returns the Updater instance registered with the given @a url. * * If no Updater is registered with the given @a url, a new one is created and * configured automatically. */

Source from the content-addressed store, hash-verified

488 * configured automatically.
489 */
490Updater* QSimpleUpdater::getUpdater(const QString& url) const
491{
492 if (!URLS.contains(url)) {
493 Updater* updater = new Updater;
494 updater->setUrl(url);
495
496 URLS.append(url);
497 UPDATERS.append(updater);
498
499 connect(updater, &Updater::checkingFinished, this, &QSimpleUpdater::checkingFinished);
500 connect(updater, &Updater::downloadFinished, this, &QSimpleUpdater::downloadFinished);
501 connect(updater, &Updater::appcastDownloaded, this, &QSimpleUpdater::appcastDownloaded);
502 }
503
504 return UPDATERS.at(URLS.indexOf(url));
505}
506
507#if QSU_INCLUDE_MOC
508# include "moc_QSimpleUpdater.cpp"

Callers

nothing calls this directly

Calls 4

containsMethod · 0.45
setUrlMethod · 0.45
appendMethod · 0.45
indexOfMethod · 0.45

Tested by

no test coverage detected