- for (int i = 0; i < c.Enumerate("http"); i++)
- {
- host = c.ReadValue("http", "host", i);
- bindip = c.ReadValue("http", "ip", i);
- port = c.ReadInteger("http", "port", i, true);
- indexfile = c.ReadValue("http", "index", i);
- index = new FileReader(ServerInstance, indexfile);
- if (!index->Exists())
- throw ModuleException("Can't read index file: "+indexfile);
- http = new HttpServerSocket(ServerInstance, bindip, port, true, 0, index);
- httpsocks.push_back(http);
- }
+ public:
+ ModuleHttpServer()
+ : APIImpl(this)
+ , acleventprov(this, "event/http-acl")
+ , reqeventprov(this, "event/http-request")
+ {
+ aclevprov = &acleventprov;
+ reqevprov = &reqeventprov;