51 lines
827 B
C++
51 lines
827 B
C++
#include <QtCore/QCoreApplication>
|
|
#include <qdebug.h>
|
|
|
|
#include "cmds_basic.h"
|
|
#include "dispatch.h"
|
|
#include "cmds.h"
|
|
|
|
dispatch::Dispatch c;
|
|
|
|
|
|
int vp(int c) {
|
|
qDebug() << c;
|
|
return c;
|
|
}
|
|
cmds::T<int(int)>::Cmd<vp> entry(&c, "hello");
|
|
|
|
namespace xproc {
|
|
int xmp(int arg) {
|
|
qDebug() << "xmp";
|
|
return 3;
|
|
}
|
|
|
|
cmds::T<int(int)>::Cmd<xmp> xvv(&c, "sfaf");
|
|
}
|
|
|
|
|
|
using namespace Inlet;
|
|
int main(int argc, char* argv[]) {
|
|
QCoreApplication a(argc, argv);
|
|
|
|
SignatureImpl<int, int> v(3);
|
|
v.execute(vp);
|
|
|
|
Callable<int, int> vptr = vp;
|
|
|
|
CmdsImpl<(void*) vp, int, int> exec;
|
|
exec.execute(5);
|
|
|
|
entry(50);
|
|
|
|
xproc::xvv(2);
|
|
|
|
|
|
return a.exec();
|
|
}
|
|
|
|
template<> void datas::dataSet<int>(IDataObject& object, const QString& key, int value) { }
|
|
template<> int datas::dataGet<int>(IDataObject& object, const QString& key) {
|
|
return 0;
|
|
}
|