PythonQtWrapper_QHttpHeader.h
62 lines
| 2.5 KiB
| text/x-c
|
CLexer
florianlink
|
r13 | #ifndef PYTHONQTWRAPPER_QHTTPHEADER_H | ||
#define PYTHONQTWRAPPER_QHTTPHEADER_H | ||||
#include <qhttp.h> | ||||
#include <QObject> | ||||
florianlink
|
r24 | #include <PythonQt.h> | ||
florianlink
|
r13 | #include <QVariant> | ||
#include <qlist.h> | ||||
#include <qpair.h> | ||||
#include <qstringlist.h> | ||||
florianlink
|
r24 | class PythonQtShell_QHttpHeader : public QHttpHeader | ||
{ | ||||
public: | ||||
PythonQtShell_QHttpHeader():QHttpHeader(),_wrapper(NULL) {}; | ||||
PythonQtShell_QHttpHeader(const QString& str):QHttpHeader(str),_wrapper(NULL) {}; | ||||
virtual int majorVersion() const; | ||||
virtual int minorVersion() const; | ||||
virtual bool parseLine(const QString& line, int number); | ||||
virtual QString toString() const; | ||||
PythonQtInstanceWrapper* _wrapper; | ||||
}; | ||||
class PythonQtPublicPromoter_QHttpHeader : public QHttpHeader | ||||
{ public: | ||||
florianlink
|
r28 | inline bool promoted_parseLine(const QString& line, int number) { return QHttpHeader::parseLine(line, number); } | ||
inline QString promoted_toString() const { return QHttpHeader::toString(); } | ||||
florianlink
|
r24 | }; | ||
florianlink
|
r13 | class PythonQtWrapper_QHttpHeader : public QObject | ||
{ Q_OBJECT | ||||
public: | ||||
public slots: | ||||
florianlink
|
r24 | QHttpHeader* new_QHttpHeader(); | ||
QHttpHeader* new_QHttpHeader(const QString& str); | ||||
florianlink
|
r13 | void delete_QHttpHeader(QHttpHeader* obj) { delete obj; } | ||
florianlink
|
r28 | bool hasContentLength(QHttpHeader* theWrappedObject) const; | ||
QStringList keys(QHttpHeader* theWrappedObject) const; | ||||
bool hasContentType(QHttpHeader* theWrappedObject) const; | ||||
florianlink
|
r24 | void setValue(QHttpHeader* theWrappedObject, const QString& key, const QString& value); | ||
void removeAllValues(QHttpHeader* theWrappedObject, const QString& key); | ||||
florianlink
|
r28 | void setContentType(QHttpHeader* theWrappedObject, const QString& type); | ||
florianlink
|
r24 | void addValue(QHttpHeader* theWrappedObject, const QString& key, const QString& value); | ||
florianlink
|
r28 | QList<QPair<QString , QString > > values(QHttpHeader* theWrappedObject) const; | ||
void removeValue(QHttpHeader* theWrappedObject, const QString& key); | ||||
void setValues(QHttpHeader* theWrappedObject, const QList<QPair<QString , QString > >& values); | ||||
florianlink
|
r13 | bool hasKey(QHttpHeader* theWrappedObject, const QString& key) const; | ||
bool isValid(QHttpHeader* theWrappedObject) const; | ||||
florianlink
|
r28 | QStringList allValues(QHttpHeader* theWrappedObject, const QString& key) const; | ||
florianlink
|
r24 | bool parseLine(QHttpHeader* theWrappedObject, const QString& line, int number); | ||
uint contentLength(QHttpHeader* theWrappedObject) const; | ||||
QString contentType(QHttpHeader* theWrappedObject) const; | ||||
QString toString(QHttpHeader* theWrappedObject) const; | ||||
florianlink
|
r28 | QString value(QHttpHeader* theWrappedObject, const QString& key) const; | ||
void setContentLength(QHttpHeader* theWrappedObject, int len); | ||||
florianlink
|
r13 | }; | ||
#endif // PYTHONQTWRAPPER_QHTTPHEADER_H | ||||