1 package LWP::Protocol::loopback;
5 require HTTP::Response;
8 @ISA = qw(LWP::Protocol);
11 my($self, $request, $proxy, $arg, $size, $timeout) = @_;
13 my $response = HTTP::Response->new(200, "OK");
14 $response->content_type("message/http; msgtype=request");
16 $response->header("Via", "loopback/1.0 $proxy")
19 $response->header("X-Arg", $arg);
20 $response->header("X-Read-Size", $size);
21 $response->header("X-Timeout", $timeout);
23 return $self->collect_once($arg, $response, $request->as_string);