Ok, the long awaited config wizard is here (at least in a very basic state). There...
[quassel.git] / src / contrib / libqxt-2007-10-24 / tests / web / invoketest / main.cpp
1 #include <QCoreApplication>
2 #include <QxtWebCore>
3 #include <QxtWebController>
4 #include <QxtScgiConnector>
5 class test : public QxtWebController
6         {
7         Q_OBJECT
8         public:
9                 test():QxtWebController("root")
10                         {
11                         }
12
13         public slots:
14
15                  int index()
16                         {
17                         echo()<<"foo";
18                         return 0;
19                         }
20                  int index(QString a, QString b=QString("default"), QString c=QString("default2"))
21                         {
22                         echo()<<"a: "<<a<<"<br/> b: "<<b<<"<br/> c: "<<c;
23                         return 0;
24                         }
25
26         };
27
28 class err : public QxtWebController
29         {
30         Q_OBJECT
31         public:
32                 err():QxtWebController("error")
33                         {
34                         }
35
36         public slots:
37
38                  int index(QString a=QString("500"),QString b=QString(),QString c=QString(),QString d=QString(),
39                         QString e=QString(),QString f=QString(),QString g=QString())
40                         {
41                         echo()<<"shits<br/>"
42                         "error "<<a<<"<br/>"
43                         <<b<<"<br/>"
44                         <<c<<"<br/>"
45                         <<d<<"<br/>"
46                         <<e<<"<br/>"
47                         <<f<<"<br/>"
48                         <<g<<"<br/>";
49                         return 0;
50                         }
51
52         };
53
54
55
56
57
58 int main(int argc, char *argv[])
59         {
60         QCoreApplication app(argc, argv);
61         QxtWebCore core(new QxtScgiConnector());
62         core.start(4000);
63         test t;
64         err e;
65         return app.exec();
66         }
67
68
69 #include "main.moc"