haiku/headers/private/netservices/FileRequest.h

55 lines
1.0 KiB
C
Raw Normal View History

2013-10-24 19:31:25 +04:00
/*
* Copyright 2013 Haiku Inc. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#ifndef _B_FILE_REQUEST_H_
#define _B_FILE_REQUEST_H_
#include <deque>
#include <UrlRequest.h>
#include <UrlProtocolRoster.h>
2013-10-24 19:31:25 +04:00
#ifndef LIBNETAPI_DEPRECATED
namespace BPrivate {
namespace Network {
#endif
2013-10-24 19:31:25 +04:00
class BFileRequest : public BUrlRequest {
public:
virtual ~BFileRequest();
const BUrlResult& Result() const;
void SetDisableListener(bool disable);
2013-10-24 19:31:25 +04:00
private:
friend class BUrlProtocolRoster;
#ifdef LIBNETAPI_DEPRECATED
BFileRequest(const BUrl& url,
BUrlProtocolListener* listener = NULL,
BUrlContext* context = NULL);
#else
BFileRequest(const BUrl& url,
BDataIO* output,
BUrlProtocolListener* listener = NULL,
BUrlContext* context = NULL);
#endif
2013-10-24 19:31:25 +04:00
status_t _ProtocolLoop();
private:
BUrlResult fResult;
2013-10-24 19:31:25 +04:00
};
#ifndef LIBNETAPI_DEPRECATED
} // namespace Network
} // namespace BPrivate
#endif
2013-10-24 19:31:25 +04:00
#endif // _B_FILE_REQUEST_H_