Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qnetworkreplyfileimpl_p.h
Go to the documentation of this file.
1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QNETWORKREPLYFILEIMPL_P_H
5#define QNETWORKREPLYFILEIMPL_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists for the convenience
12// of the Network Access API. This header file may change from
13// version to version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <QtNetwork/private/qtnetworkglobal_p.h>
19#include "qnetworkreply.h"
20#include "qnetworkreply_p.h"
22
23#include <QFile>
24#include <QtCore/qpointer.h>
25#include <private/qabstractfileengine_p.h>
26
28
31{
33public:
36 virtual void abort() override;
37
38 // reimplemented from QNetworkReply
39 virtual void close() override;
40 virtual qint64 bytesAvailable() const override;
41 virtual bool isSequential () const override;
42 qint64 size() const override;
43
44 virtual qint64 readData(char *data, qint64 maxlen) override;
45
46private Q_SLOTS:
47 void fileOpenFinished(bool isOpen);
48
49private:
50 Q_DECLARE_PRIVATE(QNetworkReplyFileImpl)
51};
52
63
65
66// ### move to qnetworkrequest.h
68 QNetworkRequest__KnownHeaders, Q_NETWORK_EXPORT)
69
70#endif // QNETWORKREPLYFILEIMPL_P_H
bool isOpen() const
Returns true if the device is open; otherwise returns false.
The QNetworkAccessManager class allows the application to send network requests and receive replies.
Operation
Indicates the operation this reply is processing.
QNetworkAccessManagerPrivate * managerPrivate
virtual void close() override
Closes this device for reading.
virtual bool isSequential() const override
QNetworkReplyFileImpl(QNetworkAccessManager *manager, const QNetworkRequest &req, const QNetworkAccessManager::Operation op)
virtual qint64 bytesAvailable() const override
Returns the number of bytes that are available for reading.
virtual void abort() override
Aborts the operation immediately and close down any network connections still open.
qint64 size() const override
For open random-access devices, this function returns the size of the device.
The QNetworkReply class contains the data and headers for a request sent with QNetworkAccessManager.
QNetworkAccessManager * manager() const
Returns the QNetworkAccessManager that was used to create this QNetworkReply object.
The QNetworkRequest class holds a request to be sent with QNetworkAccessManager.
KnownHeaders
List of known header types that QNetworkRequest parses.
Combined button and popup list for selecting options.
#define QT_DECL_METATYPE_EXTERN_TAGGED(TYPE, TAG, EXPORT)
Definition qmetatype.h:1376
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
#define Q_OBJECT
#define Q_SLOTS
long long qint64
Definition qtypes.h:60
QByteArray readData()