[Catalyst-commits] r10222 - Catalyst-Runtime/5.80/trunk/lib/Catalyst

t0m at dev.catalyst.perl.org t0m at dev.catalyst.perl.org
Thu May 21 15:42:09 GMT 2009


Author: t0m
Date: 2009-05-21 15:42:08 +0000 (Thu, 21 May 2009)
New Revision: 10222

Modified:
   Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm
Log:
Document 'env' attribute. kmx++

Modified: Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm
===================================================================
--- Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm	2009-05-21 15:11:42 UTC (rev 10221)
+++ Catalyst-Runtime/5.80/trunk/lib/Catalyst/Engine.pm	2009-05-21 15:42:08 UTC (rev 10222)
@@ -676,6 +676,18 @@
 
 <obsolete>, see finalize_body
 
+=head2 $self->env
+
+Hash containing enviroment variables including many special variables inserted
+by WWW server - like SERVER_*, REMOTE_*, HTTP_* ...
+
+Before accesing enviroment variables consider whether the same information is
+not directly available via Catalyst objects $c->request, $c->engine ...
+
+BEWARE: If you really need to access some enviroment variable from your Catalyst
+application you should use $c->engine->env->{VARNAME} instead of $ENV{VARNAME},
+as in some enviroments the %ENV hash does not contain what you would expect.
+
 =head1 AUTHORS
 
 Catalyst Contributors, see Catalyst.pm




More information about the Catalyst-commits mailing list