(self, headers=None, url=None, filename=None, body=None)
return cls
Guess the most appropriate Response class based on
        the given arguments.
Guess the most appropriate Response class based on
        the given arguments.
Guess the most appropriate Response class based on the given arguments .
def from_args(self, headers=None, url=None, filename=None, body=None):
        """Guess the most appropriate Response class based on
        the given arguments."""
        cls = Response
        if headers is not None:
            cls = self.from_headers(headers)
        if cls is Response and url is not None:
            cls = self.from_filename(url)
        if cls is Response and filename is not None:
            cls = self.from_filename(filename)
        if cls is Response and body is not None:
            cls = self.from_body(body)
        return cls
def from_args ( self , headers = None , url = None , filename = None , body = None ) : cls = Response if headers is not None : cls = self . from_headers ( headers ) if cls is Response and url is not None : cls = self . from_filename ( url ) if cls is Response and filename is not None : cls = self . from_filename ( filename ) if cls is Response and body is not None : cls = self . from_body ( body ) return cls