X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=blobdiff_plain;f=lib%2FCatalyst%2FResponse.pm;h=d22dc3c98131f22717f33d64cc9f4327c911ad2d;hp=e29380de87ce533e39f82c5a90f7b2f2893dc41a;hb=b22c66686d892bba76a150f727561f8778f3ea72;hpb=3fde004fb4834f17f75d0966097ff0094069402d diff --git a/lib/Catalyst/Response.pm b/lib/Catalyst/Response.pm index e29380d..d22dc3c 100644 --- a/lib/Catalyst/Response.pm +++ b/lib/Catalyst/Response.pm @@ -11,44 +11,56 @@ Catalyst::Response - Catalyst Response Class =head1 SYNOPSIS -See L. + $resp = $c->response; + $resp->cookies; + $resp->headers; + $resp->output; + $resp->redirect; + $resp->status; + +See also L. =head1 DESCRIPTION -The Catalyst Response. +This is the Catalyst Response class, which provides a set of accessors to +response data. + +=head1 METHODS -=head2 METHODS +=over 4 -=head3 cookies +=item $resp->cookies -Returns a hashref containing the cookies. +Returns a reference to a hash containing the cookies. $c->response->cookies->{foo} = { value => '123' }; -=head3 headers +=item $resp->headers Returns a L object containing the headers. $c->response->headers->header( 'X-Catalyst' => $Catalyst::VERSION ); -=head3 output +=item $resp->output($text) Contains the final output. $c->response->output('Catalyst rockz!'); -=head3 redirect +=item $resp->redirect($url) Contains a location to redirect to. $c->response->redirect('http://slashdot.org'); -=head3 status +=item status Contains the HTTP status. $c->response->status(404); +=back + =head1 AUTHOR Sebastian Riedel, C