.\" Automatically generated by Pod::Man 2.28 (Pod::Simple 3.29) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{ . if \nF \{ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "POE::Component::Client::HTTP::Request 3pm" .TH POE::Component::Client::HTTP::Request 3pm "2016-07-16" "perl v5.22.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" POE::Component::Client::HTTP::Request \- an HTTP request class .SH "VERSION" .IX Header "VERSION" version 0.949 .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 1 \& # Used internally by POE::Component::Client::HTTP .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" POE::Component::Client::HTTP::Request encapsulates the state of requests POE::Component::Client::HTTP requests throughout their life cycles. There turns out to be a lot of state to manage. .SH "CONSTRUCTOR" .IX Header "CONSTRUCTOR" .SS "new \s-1NAMED_PARAMETERS\s0" .IX Subsection "new NAMED_PARAMETERS" Create a POE::Component::Client::HTTP object to manage a request. The constructor takes several named parameters: .IP "Request => \s-1HTTP_REQUEST\s0" 2 .IX Item "Request => HTTP_REQUEST" A POE::Component::Client::HTTP::Request object encapsulates a plain HTTP::Request. Required. .IP "Factory => \s-1POE_COMPONENT_CLIENT_HTTP_REQUESTFACTORY\s0" 2 .IX Item "Factory => POE_COMPONENT_CLIENT_HTTP_REQUESTFACTORY" The request may create additional requests during its lifetime, for example when following redirects. The Factory parameter specifies the POE::Component::Client::HTTP::RequestFactory that may be used to create them. Required. .IP "Postback => \s-1RESPONSE_POSTBACK\s0" 2 .IX Item "Postback => RESPONSE_POSTBACK" POE::Component::Client::HTTP creates a postback that will be used to send responses to the requesting session. Required. .IP "Progress => \s-1PROGRESS_POSTBACK\s0" 2 .IX Item "Progress => PROGRESS_POSTBACK" Sets the progress notification if the user has requested progress events. Optional. .IP "Proxy" 2 .IX Item "Proxy" Sets the proxy used for this request, if requested by the user. Optional. .SH "METHODS" .IX Header "METHODS" .SS "\s-1ID\s0" .IX Subsection "ID" Return the request's unique \s-1ID.\s0 .SS "return_response" .IX Subsection "return_response" Sends a response back to the user's session. Called by POE::Component::Client::HTTP when a complete response has arrived. .SS "add_eof" .IX Subsection "add_eof" Called by POE::Component::Client::HTTP to indicate \s-1EOF\s0 has arrived. .SS "add_content \s-1PARSED_DATA\s0" .IX Subsection "add_content PARSED_DATA" Called by POE::Component::Client::HTTP to add content data to an incrementally built response. If \s-1PARSED_DATA\s0 is an object, it is treated like an HTTP::Headers object and its headers are assimilated into the response being built by the request. Otherwise the \&\s-1PARSED_DATA\s0 is appended to the response's content. .SS "timer \s-1TIMER\s0" .IX Subsection "timer TIMER" Accessor to manipulate the request's timeout timer. Sets the request's timer if \s-1TIMER\s0 is specified, otherwise merely fetches the one currently associated with the request. .SS "create_timer \s-1TIMEOUT\s0" .IX Subsection "create_timer TIMEOUT" Creates and sets a timer for this request. \s-1TIMEOUT\s0 is the number of seconds this request may live. .SS "remove_timeout" .IX Subsection "remove_timeout" Turn off the timer associated with this request, and discard it. .SS "postback \s-1POSTBACK\s0" .IX Subsection "postback POSTBACK" Accessor to manipulate the postback associated with this request. Sets the postback if \s-1POSTBACK\s0 is defined, otherwise merely fetches it. .SS "does_redirect \s-1SOMETHING\s0" .IX Subsection "does_redirect SOMETHING" \&\s-1FIXME \-\s0 Not sure what this accessor does. .SS "check_redirect" .IX Subsection "check_redirect" Check whether the last response is a redirect, the request is permitted to follow redirects, and the maximum number of redirects has not been met. Initiate a redirect if all conditions are favorable. .SS "close_connection" .IX Subsection "close_connection" Each active request object contains an internal connection. This method closes it. .SS "send_to_wheel" .IX Subsection "send_to_wheel" Transmit the request to the socket associated with this request. .SS "wheel" .IX Subsection "wheel" An accessor to return the wheel associated with this request. .SS "error \s-1ERROR_CODE, ERROR_MESSAGE\s0" .IX Subsection "error ERROR_CODE, ERROR_MESSAGE" Generate an error response, and post it back to the user's session. .SS "connect_error \s-1CONNECT_FAILURE_MESSAGE\s0" .IX Subsection "connect_error CONNECT_FAILURE_MESSAGE" Generate a connection error response, and post it back to the user's session. .SS "host" .IX Subsection "host" Return the host this request is attempting to work with. .SS "port" .IX Subsection "port" Return the port this request is attempting to work with. .SS "scheme" .IX Subsection "scheme" Return the scheme for this request. .SH "SEE ALSO" .IX Header "SEE ALSO" POE::Component::Client::HTTP \&\s-1POE\s0 .SH "BUGS" .IX Header "BUGS" None are currently known. .SH "AUTHOR & COPYRIGHTS" .IX Header "AUTHOR & COPYRIGHTS" POE::Component::Client::HTTP::Request is .IP "\(bu" 2 Copyright 2004\-2005 Martijn van Beers .IP "\(bu" 2 Copyright 2006 Rocco Caputo .PP All rights are reserved. POE::Component::Client::HTTP::Request is free software; you may redistribute it and/or modify it under the same terms as Perl itself. .SH "CONTRIBUTORS" .IX Header "CONTRIBUTORS" Your name could be here. .SH "CONTACT" .IX Header "CONTACT" Rocco may be contacted by e\-mail via , and Martijn may be contacted by email via . .PP The preferred way to report bugs or requests is through \s-1RT\s0 though. See or mail .PP For questions, try the \s-1POE\s0 mailing list (poe@perl.org)