rename dir

This commit is contained in:
pengfei.zhou
2019-12-21 21:55:53 +08:00
parent 15d3a1cbf7
commit f21732f551
35 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
#ifndef CUSTOM_CALLBACK_H
#define CUSTOM_CALLBACK_H
#include <QDebug>
#include "async/callback.h"
template <class R>
class CustomCallback : public Callback<R> {
public:
void onResult(R result) override {
qDebug() << result;
}
void onError(QException exception) override {
qDebug() << exception.what();
}
void onFinish() override {
}
};
#endif // CUSTOM_CALLBACK_H

View File

@@ -0,0 +1,25 @@
#ifndef SINGLETON_H
#define SINGLETON_H
#include <QDebug>
class Singleton
{
private:
static Singleton *local_instance;
Singleton() {
qDebug() << "constructor";
}
~Singleton() {
qDebug() << "destructor";
}
public:
static Singleton *getInstance() {
static Singleton locla_s;
return &locla_s;
}
};
#endif // SINGLETON_H