httpd-apreq-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject cvs commit: httpd-apreq-2/glue/perl/xsbuilder/Apache/Cookie Cookie_pm
Date Sun, 25 Jul 2004 06:00:56 GMT
joes        2004/07/24 23:00:56

  Modified:    glue/perl/docs Cookie.pod
               glue/perl/xsbuilder/Apache/Cookie Cookie_pm
  Log:
  It makes more sense to bind the quote operator for Apache::Coolie to as_string() instead
of raw_value().
  
  Revision  Changes    Path
  1.10      +10 -8     httpd-apreq-2/glue/perl/docs/Cookie.pod
  
  Index: Cookie.pod
  ===================================================================
  RCS file: /home/cvs/httpd-apreq-2/glue/perl/docs/Cookie.pod,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- Cookie.pod	25 Jul 2004 05:49:10 -0000	1.9
  +++ Cookie.pod	25 Jul 2004 06:00:56 -0000	1.10
  @@ -68,6 +68,8 @@
   accessing the incoming params and file uploads.
   
   
  +
  +
   =head2 C<< new($env, %args) >>
   
   
  @@ -267,16 +269,18 @@
   
   =head2 C<< as_string() >>
   
  -Format the cookie object as a string:
  +Format the cookie object as a string.  The quote-operator for Apache::Cookie 
  +is overloaded to run this method whenever a cookie appears in quotes.
  +
   
   =for example begin
   
  -    print $cookie->as_string;
  +    ok "$cookie" eq $cookie->as_string;
   
   =for example end
   
   =for example_testing
  -    ok substr($_STDOUT_, 0, 8) eq "foo=bar;";
  +    ok substr("$cookie", 0, 8) eq "foo=bar;";
   
   
   
  @@ -336,13 +340,11 @@
   =head2 C<< raw_value() >>
   
   Gets the raw (opaque) value string as it appears in the incoming
  -"Cookie" header.  The quote-operator for Apache::Cookie is 
  -overloaded to run this method whenever a cookie appears in quotes.
  +"Cookie" header.  
   
   =for example begin
   
       ok $cookie->raw_value eq "bar";
  -    ok "$cookie" eq "bar";
   
   =for example end
   
  @@ -516,9 +518,9 @@
   
   =for example_testing
       ok "foobarfoo" eq join "", keys %$cookies;
  -    ok 123 == join "", map "$_", values %$cookies;
  +    ok 123 == join "", map $_->value, values %$cookies;
       ok "barfoo" eq join "", sort keys %cookies; # %cookies lost original foo cookie
  -    ok 23 == join "", sort map "$_", values %cookies;
  +    ok 23 == join "", sort map $_->value, values %cookies;
   
   
   
  
  
  
  1.24      +1 -1      httpd-apreq-2/glue/perl/xsbuilder/Apache/Cookie/Cookie_pm
  
  Index: Cookie_pm
  ===================================================================
  RCS file: /home/cvs/httpd-apreq-2/glue/perl/xsbuilder/Apache/Cookie/Cookie_pm,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -r1.23 -r1.24
  --- Cookie_pm	25 Jul 2004 05:25:38 -0000	1.23
  +++ Cookie_pm	25 Jul 2004 06:00:56 -0000	1.24
  @@ -30,7 +30,7 @@
   
   
   package Apache::Cookie;
  -use overload '""' => sub { shift->raw_value };
  +use overload '""' => sub { shift->as_string };
   
   sub jar {
       my ($self, $env) = @_;
  
  
  

Mime
View raw message