01: package vicazh.hyperpool.stream.net.http;
02:
03: import vicazh.hyperpool.stream.*;
04:
05: class ProtocolConnection extends Connection {
06: ProtocolConnection(Element element) {
07: super (element);
08: }
09:
10: protected Session getSession() {
11: return new ProtocolSession(this );
12: }
13:
14: int index;
15:
16: synchronized public void close() {
17: super .close();
18: notifyAll();
19: }
20:
21: synchronized public void remove(Session session) {
22: super .remove(session);
23: if (getSessions().size() == 1)
24: notify();
25: }
26: }
|