POE::C...actory(3pm)

πŸ“¦
version 0.949 Β· 5 versions
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ¦‹ POE::Component::Client::HTTP::RequestFactory β€” the vibe

okay bestie, welcome to POE::Component::Client::HTTP::RequestFactory, aka an HTTP request factory object. That's the whole name, we're not shortening it, it's iconic πŸ’…

This page lives in the User Contributed Perl Documentation section, filed under manual page 3pm (we're folding that in so it doesn't just sit there awkwardly at the top).

Version: 0.949 ✨ β€” yes, girl, we know the version, it's right there.


✨ SYNOPSIS ✨

# Used internally by POE::Component::Client::HTTP

That's it. That's the synopsis. She's a private girlie, she's for internal use, no cap. πŸŽ€


πŸ’– CONSTRUCTOR πŸ’–

new

Creates a brand-new request factory object, slay. She wants her parameters handed to her in a hashref, like the main character she is. 🫢

The following parameters get accepted β€” and if you want the full tea on any of them, they're explained in detail in POE::Component::Client::HTTP:

  • Agent
  • MaxSize
  • Streaming
  • Protocol
  • From
  • CookieJar
  • NoProxy
  • Proxy
  • FollowRedirects
  • Timeout

All ten. Counted them twice. No skips, no skimming, periodt. πŸ‘‘


🌈 METHODS 🌈

timeout [$timeout]

The method that lets you query and/or change the timeout value for requests created by this factory. She's flexible like that. πŸ’œ

is_streaming

Accessor for the Streaming parameter. Just vibes, just reading. ✨

agent

Accessor to the Agent parameter. Say hi to her. 🌸

from

Getter/setter for the From parameter. Read it, write it, whatever you need, bestie. πŸŽ€

create_request

Creates a new POE::Component::Client::HTTP::Request. She's making babies (objects). πŸ¦‹

max_response_size

Method to retrieve the maximum size of a response, as set by the "MaxSize" parameter to Client::HTTP's "spawn()" method. Big fan of boundaries honestly. πŸ’…

block_size

Accessor for the Streaming parameter. (Yes, same parameter as is_streaming β€” she contains multitudes. πŸ™ˆ)

frob_cookies $response

Stores the cookies from the HTTP::Response parameter passed in, straight into our cookie jar. Cookie jar stays stocked, as she should. πŸ“

max_redirect_count [$count]

Function to get/set the maximum number of redirects to follow automatically. This lets you retrieve or modify the value you passed with the FollowRedirects parameter to Client::HTTP's "spawn" method. πŸ”₯

parse_proxy $proxy

This one is a static method, used for parsing proxies. The $proxy can be:

parse_proxy() returns an array reference of two-element tuples (which are also array references), each one holding a host and a port:

[ [ host1, port1 ],
  [ host2, port2 ],
  ...
]

Nested arrays, nested energy. 🧚


Heads up bestie: this whole thing is documented as used internally by POE::Component::Client::HTTP, so if you're poking at it directly, know what you're doing. πŸ’€

okay that's the page!! every single parameter, every method, every return shape, all of it, preserved like a pressed flower 🌸

cute sign-off time: this page is from perl v5.36.0, dated 2022-11-19, and it belongs to the POE::C...actory(3pm) manual page. mwah πŸ’‹ bye bestie!!

πŸ“¦ where this page comes from