xref: /haiku/src/add-ons/kernel/file_systems/netfs/headers/shared/RequestChannel.h (revision 5a1d355fdf2747f80f8c46e2539f844a0b813346)
1 // RequestChannel.h
2 
3 #ifndef NET_FS_REQUEST_CHANNEL_H
4 #define NET_FS_REQUEST_CHANNEL_H
5 
6 #include <SupportDefs.h>
7 
8 class Channel;
9 class Request;
10 
11 class RequestChannel {
12 public:
13 								RequestChannel(Channel* channel);
14 								~RequestChannel();
15 
16 			status_t			SendRequest(Request* request);
17 			status_t			ReceiveRequest(Request** request);
18 
19 private:
20 			status_t			_GetRequestSize(Request* request, int32* size);
21 
22 private:
23 			class ChannelWriter;
24 			class MemoryReader;
25 			struct RequestHeader;
26 
27 			Channel*			fChannel;
28 			void*				fBuffer;
29 			int32				fBufferSize;
30 };
31 
32 #endif	// NET_FS_REQUEST_CHANNEL_H
33