comparison asyncdreactor/protocol/Http11.d @ 11:5836613d16ac

reorg! reorg!
author rick@minifunk
date Tue, 12 Aug 2008 16:59:56 -0400
parents dreactor/protocol/Http11.d@e75a2e506b1d
children
comparison
equal deleted inserted replaced
10:e75a2e506b1d 11:5836613d16ac
1 module dreactor.protocol.Http11;
2
3 import dreactor.protocol.RawTcp;
4 import dreactor.protocol.http11_parser;
5
6 class HttpListener
7 {
8 public
9 this(Vat sel, IPv4Address addr)
10 {
11 listener = new RawTCPListener(sel, IPv4Address addr);
12 parser = new Http11Parser();
13 listener.setDataHandler(&onData);
14 }
15
16 private int onData(char[] buffer)
17 {
18 parser.execute(buffer);
19 }
20
21
22 private
23 RawTCPListener listener;
24 Http11Parser parser;
25 }
26
27 class HttpClient
28 {
29 public
30 this(Vat sel)
31 {
32 client = new RawTCPClient(sel);
33 client.setDataHandler(&onData);
34 }
35
36 private int onData()
37 {
38
39 }
40 private
41 RawTCPClient client;
42 }
43