read_until() public method

public read_until ( byte delimiter, Action callback ) : void
delimiter byte
callback Action
return void
コード例 #1
0
ファイル: httpserver.cs プロジェクト: swax/Tornado.Net
 public HTTPConnection(IOStream stream_, IPEndPoint address_, Func<HTTPRequest, RequestHandler> request_callback_, bool no_keep_alive_ = false, bool xheaders_ = false)
 {
     stream = stream_;
     address = address_;
     request_callback = request_callback_;
     no_keep_alive = no_keep_alive_;
     xheaders = xheaders_;
     _request = null;
     _request_finished = false;
     // Save stack context here, outside of any request.  This keeps
     // contexts from one request from leaking into the next.
     _header_callback = _on_headers; //stack_context.wrap(self._on_headers);
     stream.read_until(Encoding.UTF8.GetBytes("\r\n\r\n"), _header_callback);
     _write_callback = null;
 }