++ed by:
ROMANF TOKUHIROM SYP NQOUNET IONCACHE

13 PAUSE users
16 non-PAUSE users.

MATSUNO★…Tokuhiro
and 1 contributors

NAME

Furl::Response - Response object for Furl

SYNOPSIS

    my $res = Furl::Response->new($minor_version, $code, $message, $headers, $content);
    print $res->status, "\n";

DESCRIPTION

This is a HTTP response object in Furl.

CONSTRUCTOR

    my $res = Furl::Response->new($minor_version, $code, $msg, \%headers, $content);

INSTANCE METHODS

$res->code
$res->status

Returns HTTP status code.

$res->message

Returns HTTP status message.

$res->headers

Returns instance of Furl::Headers

$res->content
$res->body

Returns response body in scalar.

$res->content_length
$res->content_type
$res->content_encoding
$res->header

Shorthand to access Furl::Headers.

$res->protocol
    $res->protocol(); # => "HTTP/1.1"

Returns HTTP protocol in string.

$res->as_http_response

Make instance of HTTP::Response from Furl::Response.

$res->is_success

Returns true if status code is 2xx.

$res->status_line
    $res->status_line() # => "200 OK"

Returns status line.