Skip to content

bidstack/bidstack-giantswarm

Repository files navigation

bidstack-giantswarm

GiantSwarm API client written in Qt/C++

Usage

#include <QCoreApplication>
#include <QDebug>
#include <QSqlDatabase>
#include <QSqlError>

#include "giantswarmclient.hpp"

using namespace Bidstack::Giantswarm;

int main(int argc, char *argv[]) {
    QCoreApplication app(argc, argv);

    QSqlDatabase database = QSqlDatabase::addDatabase("QSQLITE", "giantswarm");
    database.setDatabaseName("giantswarm.db");

    if (!database.isValid()) {
        qWarning() << "Could not set database name probably due to invalid driver.";
    } else if (!database.open()) {
        qWarning() << "Could not open connection to database:" << database.lastError().text();
    }

    GiantswarmClient giantswarm(database);
    qDebug() << "Ping:" << (giantswarm.ping() ? "successful" : "failed");

    return 0;
}

About

GiantSwarm API client written in Qt/C++

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages