コード例 #1
0
ファイル: HttpServer.cs プロジェクト: keelanstuart/Sherpa
        public HttpServer(int initial_port = defaultPort, string initial_rootdir = defaultRootDir)
        {
            evShutdown = new AutoResetEvent(false);
            evSettings = new AutoResetEvent(true);
            evStart    = new AutoResetEvent(false);
            evStop     = new AutoResetEvent(false);
            evServed   = new AutoResetEvent(false);

            rootDirMutex = new Mutex(false);

            requestCount = 0;

            port            = initial_port;
            rootDir         = initial_rootdir;
            curState        = State.Inactive;
            logFunc         = null;
            reportStateFunc = null;

            serverThread = null;
        }
コード例 #2
0
ファイル: HttpServer.cs プロジェクト: keelanstuart/Sherpa
 public void SetLogFunc(logFuncType userLogFunc)
 {
     logFunc = userLogFunc;
 }