1 #ifndef _KviHttpRequest_h_
2 #define _KviHttpRequest_h_
32 #endif // otherwise QTextStream freaks out
34 #include <QTextStream>
43 #include <QtNetwork/QAbstractSocket>
116 return m_bFollowRedirects;
121 m_bFollowRedirects = bFollow;
126 m_uMaximumRedirectCount = uCount;
131 m_uConnectionTimeout = uConnectionTimeout;
132 if(m_uConnectionTimeout < 5)
133 m_uConnectionTimeout = 5;
139 const QString &
fileName() {
return m_szFileName; };
148 void setPostData(
const QString & szPostData) { m_szPostData = szPostData; };
156 void setFileName(
const QString & szFileName) { m_szFileName = szFileName; };
165 bool get(
const KviUrl &
u, ProcessingType
p = WholeFile,
const QString & szFileName = QString());
171 void resolvingHost(
const QString &
hostname);
172 void contactingHost(
const QString & ipandport);
173 void connectionEstablished();
174 void receivedResponse(
const QString & response);
176 void terminated(
bool bSuccess);
178 void status(
const QString & message);
182 void requestSent(
const QStringList & request);
195 void resetInternalStatus();
198 void slotSocketReadDataReady();
199 void slotSocketDisconnected();
200 void slotSocketConnected();
201 void slotSocketError(QAbstractSocket::SocketError socketError);
202 void slotConnectionTimedOut();
203 void slotSocketHostResolved();
206 #endif //_KviHttpRequest_h_
const QString & fileName()
Definition: KviHttpRequest.h:139
unsigned int m_uContentOffset
Definition: KviHttpRequest.h:92
void setPostData(const QString &szPostData)
Definition: KviHttpRequest.h:148
unsigned int m_uConnectionTimeout
Definition: KviHttpRequest.h:107
void setMaximumRedirectCount(unsigned int uCount)
Definition: KviHttpRequest.h:124
Definition: KviHeapObject.h:124
void setConnectionTimeout(unsigned int uConnectionTimeout)
Definition: KviHttpRequest.h:129
void setContentOffset(int uContentOffset)
Definition: KviHttpRequest.h:160
unsigned int totalSize()
Definition: KviHttpRequest.h:143
Definition: KviCString.h:105
void setMaxContentLength(int uMaxContentLength)
Definition: KviHttpRequest.h:158
void setUrl(const KviUrl &u)
Definition: KviHttpRequest.h:149
#define a
Definition: detector.cpp:91
unsigned int m_uReceivedSize
Definition: KviHttpRequest.h:99
KviUrl m_url
Definition: KviHttpRequest.h:86
Definition: KviHttpRequest.h:73
bool m_bGzip
Definition: KviHttpRequest.h:104
Definition: KviHttpRequest.h:74
void setExistingFileAction(ExistingFileAction a)
Definition: KviHttpRequest.h:155
bool m_bChunkedTransferEncoding
Definition: KviHttpRequest.h:103
Definition: KviHttpRequest.h:67
bool m_bFollowRedirects
Definition: KviHttpRequest.h:94
ExistingFileAction
Definition: KviHttpRequest.h:71
unsigned int receivedSize()
Definition: KviHttpRequest.h:144
const QString & lastError()
Definition: KviHttpRequest.h:167
KviUrl m_connectionUrl
Definition: KviHttpRequest.h:101
Definition: KviDataBuffer.h:30
Definition: KviHttpRequest.h:75
Definition: KviHttpRequest.h:66
Definition: KviHttpRequest.h:64
Definition: KviHttpRequest.cpp:46
QString m_szPostData
Definition: KviHttpRequest.h:93
void * privateData()
Definition: KviHttpRequest.h:140
unsigned int maxContentLength()
Definition: KviHttpRequest.h:141
void setFileName(const QString &szFileName)
Definition: KviHttpRequest.h:156
KviHttpRequestPrivate * m_p
Definition: KviHttpRequest.h:111
QString m_szFileName
Definition: KviHttpRequest.h:87
bool followRedirects() const
Definition: KviHttpRequest.h:114
void setPrivateData(void *ptr)
Definition: KviHttpRequest.h:157
unsigned int m_uRedirectCount
Definition: KviHttpRequest.h:108
The KviDnsResolver class.
Definition: KviDnsResolver.h:93
unsigned int contentOffset()
Definition: KviHttpRequest.h:142
ProcessingType
Definition: KviHttpRequest.h:62
QString m_szLastError
Definition: KviHttpRequest.h:97
unsigned int m_uRemainingChunkSize
Definition: KviHttpRequest.h:105
Definition: KviHttpRequest.h:65
void setProcessingType(ProcessingType t)
Definition: KviHttpRequest.h:154
QHashIterator< int, QFile * > t(getDict)
Definition: KviHttpRequest.h:58
bool m_bIgnoreRemainingData
Definition: KviHttpRequest.h:106
ExistingFileAction existingFileAction()
Definition: KviHttpRequest.h:138
ProcessingType m_eProcessingType
Definition: KviHttpRequest.h:88
unsigned int m_uMaximumRedirectCount
Definition: KviHttpRequest.h:95
ExistingFileAction m_eExistingFileAction
Definition: KviHttpRequest.h:89
void * m_pPrivateData
Definition: KviHttpRequest.h:90
#define u
Definition: detector.cpp:85
unsigned int m_uTotalSize
Definition: KviHttpRequest.h:98
A fast pointer hash table implementation.
Definition: KviPointerHashTable.h:391
bool m_bHeaderProcessed
Definition: KviHttpRequest.h:102
unsigned int m_uMaxContentLength
Definition: KviHttpRequest.h:91
This file contains compile time settings.
#define p
Definition: detector.cpp:80
ProcessingType processingType()
Definition: KviHttpRequest.h:137
void setFollowRedirects(bool bFollow)
Definition: KviHttpRequest.h:119
#define KVILIB_API
Definition: kvi_settings.h:125
QString hostname()
Definition: KviRuntimeInfo.cpp:720
const KviUrl & url()
Definition: KviHttpRequest.h:136