etwist/request.py
branchtls-sprint
changeset 1802 d628defebc17
parent 1016 26387b836099
child 1977 606923dff11b
equal deleted inserted replaced
1801:672acc730ce5 1802:d628defebc17
    37         self._headers = req.headers
    37         self._headers = req.headers
    38 
    38 
    39     def base_url(self):
    39     def base_url(self):
    40         """return the root url of the application"""
    40         """return the root url of the application"""
    41         return self._base_url
    41         return self._base_url
    42     
    42 
    43     def http_method(self):
    43     def http_method(self):
    44         """returns 'POST', 'GET', 'HEAD', etc."""
    44         """returns 'POST', 'GET', 'HEAD', etc."""
    45         return self._twreq.method
    45         return self._twreq.method
    46     
    46 
    47     def relative_path(self, includeparams=True):
    47     def relative_path(self, includeparams=True):
    48         """return the normalized path of the request (ie at least relative
    48         """return the normalized path of the request (ie at least relative
    49         to the application's root, but some other normalization may be needed
    49         to the application's root, but some other normalization may be needed
    50         so that the returned path may be used to compare to generated urls
    50         so that the returned path may be used to compare to generated urls
    51 
    51