Fix FreeBSD build.
[haiku.git] / headers / os / net / GopherRequest.h
blobad38f96ade1203d56f8559a8b0b5f1772d42e823
1 /*
2 * Copyright 2014 Haiku Inc. All rights reserved.
3 * Distributed under the terms of the MIT License.
4 */
5 #ifndef _B_GOPHER_REQUEST_H_
6 #define _B_GOPHER_REQUEST_H_
9 #include <deque>
11 #include <NetworkRequest.h>
14 class BGopherRequest : public BNetworkRequest {
15 public:
16 BGopherRequest(const BUrl& url,
17 BUrlProtocolListener* listener = NULL,
18 BUrlContext* context = NULL);
19 virtual ~BGopherRequest();
21 status_t Stop();
22 const BUrlResult& Result() const;
23 void SetDisableListener(bool disable);
25 private:
26 status_t _ProtocolLoop();
27 void _SendRequest();
29 bool _NeedsParsing();
30 bool _NeedsLastDotStrip();
31 void _ParseInput(bool last);
33 BString& _HTMLEscapeString(BString &str);
35 private:
36 char fItemType;
37 BString fPath;
39 ssize_t fPosition;
41 BUrlResult fResult;
45 #endif // _B_GOPHER_REQUEST_H_