You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apreq-cvs@httpd.apache.org by jo...@apache.org on 2005/09/06 22:54:30 UTC

svn commit: r279103 - in /httpd/apreq/trunk: CHANGES glue/perl/xsbuilder/APR/Request/Param/Param.pm glue/perl/xsbuilder/APR/Request/Request.pm

Author: joes
Date: Tue Sep  6 13:54:25 2005
New Revision: 279103

URL: http://svn.apache.org/viewcvs?rev=279103&view=rev
Log:
Move APR::Request::upload to APR::Request.

Modified:
    httpd/apreq/trunk/CHANGES
    httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Param/Param.pm
    httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Request.pm

Modified: httpd/apreq/trunk/CHANGES
URL: http://svn.apache.org/viewcvs/httpd/apreq/trunk/CHANGES?rev=279103&r1=279102&r2=279103&view=diff
==============================================================================
--- httpd/apreq/trunk/CHANGES (original)
+++ httpd/apreq/trunk/CHANGES Tue Sep  6 13:54:25 2005
@@ -5,6 +5,9 @@
 @section v2_07 Changes with libapreq2-2.07
 
 
+- Perl API [joes]
+  Move APR::Request::upload to APR::Request, where it belongs.
+
 - Perl XS [Nikolay Ananiev]
   Use MP_STATIC declarations to allow Cygwin builds.
 

Modified: httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Param/Param.pm
URL: http://svn.apache.org/viewcvs/httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Param/Param.pm?rev=279103&r1=279102&r2=279103&view=diff
==============================================================================
--- httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Param/Param.pm (original)
+++ httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Param/Param.pm Tue Sep  6 13:54:25 2005
@@ -16,22 +16,6 @@
     return $fh;
 }
 
-sub APR::Request::upload {
-    my $req = shift;
-    my $body = $req->body or return;
-    $body->param_class(__PACKAGE__);
-    if (@_) {
-        my @uploads = grep $_->upload, $body->get(@_);
-        return wantarray ? @uploads : $uploads[0];
-    }
-
-    return map { $_->upload ? $_->name : () } values %$body
-        if wantarray;
-
-   return $body->uploads($req->pool);
-
-}
-
 package APR::Request::Brigade;
 push our(@ISA), "APR::Brigade";
 

Modified: httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Request.pm
URL: http://svn.apache.org/viewcvs/httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Request.pm?rev=279103&r1=279102&r2=279103&view=diff
==============================================================================
--- httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Request.pm (original)
+++ httpd/apreq/trunk/glue/perl/xsbuilder/APR/Request/Request.pm Tue Sep  6 13:54:25 2005
@@ -16,5 +16,21 @@
     return ($req->args_status, $req->body_status);
 }
 
+sub upload {
+    require APR::Request::Param;
+    my $req = shift;
+    my $body = $req->body or return;
+    $body->param_class("APR::Request::Param");
+    if (@_) {
+        my @uploads = grep $_->upload, $body->get(@_);
+        return wantarray ? @uploads : $uploads[0];
+    }
+
+    return map { $_->upload ? $_->name : () } values %$body
+        if wantarray;
+
+   return $body->uploads($req->pool);
+}
+
 package APR::Request::Custom;
 our @ISA = qw/APR::Request/;