(self, server, conn, proxy_mode=False, strict_mode=True)
Initialize HTTP request container instance.

        Args:
            server (HTTPServer): web server object receiving this request
            conn (HTTPConnection): HTTP connection object for this request
            proxy_mode (bool): whether this HTTPServer should behave as a PROXY
            server for certain requests
            strict_mode (bool): whether we should return a 400 Bad Request when
            we encounter a request that a HTTP compliant client should not be
            making
Initialize HTTP request container instance.
Initialize HTTP request container instance .
def __init__(self, server, conn, proxy_mode=False, strict_mode=True):
        """Initialize HTTP request container instance.

        Args:
            server (HTTPServer): web server object receiving this request
            conn (HTTPConnection): HTTP connection object for this request
            proxy_mode (bool): whether this HTTPServer should behave as a PROXY
            server for certain requests
            strict_mode (bool): whether we should return a 400 Bad Request when
            we encounter a request that a HTTP compliant client should not be
            making
        """
        self.server = server
        self.conn = conn

        self.ready = False
        self.started_request = False
        self.scheme = b'http'
        if self.server.ssl_adapter is not None:
            self.scheme = b'https'
        # Use the lowest-common protocol in case read_request_line errors.
        self.response_protocol = 'HTTP/1.0'
        self.inheaders = {}

        self.status = ''
        self.outheaders = []
        self.sent_headers = False
        self.close_connection = self.__class__.close_connection
        self.chunked_read = False
        self.chunked_write = self.__class__.chunked_write
        self.proxy_mode = proxy_mode
        self.strict_mode = strict_mode
def __init__ ( self , server , conn , proxy_mode = False , strict_mode = True ) : self . server = server self . conn = conn self . ready = False self . started_request = False self . scheme = b'http' if self . server . ssl_adapter is not None : self . scheme = b'https' # Use the lowest-common protocol in case read_request_line errors. self . response_protocol = 'HTTP/1.0' self . inheaders = { } self . status = '' self . outheaders = [ ] self . sent_headers = False self . close_connection = self . __class__ . close_connection self . chunked_read = False self . chunked_write = self . __class__ . chunked_write self . proxy_mode = proxy_mode self . strict_mode = strict_mode