示例#1
0
 def __init__(self, **kwargs):
     HTTPResponse.__init__(self, HTTPPreamble(status_code=httplib.CREATED, **kwargs))
示例#2
0
 def __init__(self, body="", **kwargs):
     HTTPResponse.__init__(self, HTTPPreamble(status_code=httplib.INTERNAL_SERVER_ERROR, **kwargs), body=body)
示例#3
0
 def __init__(self, allowed, body="", **kwargs):
     HTTPResponse.__init__(
         self,
         HTTPPreamble(status_code=httplib.METHOD_NOT_ALLOWED, headers={"Allowed": allowed}, **kwargs),
         body=body,
     )
示例#4
0
 def __init__(self, body="", **kwargs):
     HTTPResponse.__init__(self, HTTPPreamble(status_code=httplib.NOT_IMPLEMENTED, **kwargs), body=body)
示例#5
0
 def __init__(self, body="", **kwargs):
     HTTPResponse.__init__(self, HTTPPreamble(status_code=httplib.FORBIDDEN, **kwargs), body=body)
示例#6
0
 def __init__(self, body="", **kwargs):
     HTTPResponse.__init__(self, HTTPPreamble(status_code=httplib.UNAUTHORIZED, **kwargs), body=body)
示例#7
0
 def __init__(self, body="", **kwargs):
     HTTPResponse.__init__(self, HTTPPreamble(status_code=httplib.BAD_REQUEST, **kwargs), body=body)
示例#8
0
 def __init__(self, location, body="", **kwargs):
     HTTPResponse.__init__(
         self, HTTPPreamble(status_code=httplib.FOUND, headers={"Location": location}, **kwargs), body=body
     )
示例#9
0
 def __init__(self, **kwargs):
     HTTPResponse.__init__(self, HTTPPreamble(status_code=httplib.NO_CONTENT, **kwargs))