XML::RPC::UA(3pm)

πŸ“¦
version 0.8 Β· 2 versions
  • 0.8 Β· debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking (latest)
  • 0.8 Β· ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– XML::RPC::UA πŸ’–

okay so bestie, welcome to XML::RPC::UA β€” the base class for XML::RPC UserAgent. It's giving "blueprint energy" ✨ β€” it's the vibe template that all the actual useragent classes inherit from, and it ships from the User Contributed Perl Documentation pile, page XML::RPC::UA(3pm). πŸŽ€


🌈 SYNOPSIS 🌈

Generic usage, no cap:

use XML::RPC::Fast;

my $client = XML::RPC::Fast->new(
    $uri,
    ua => XML::RPC::UA::LWP->new(
        timeout => 10,
        ua => 'YourApp/0.01', # default User-Agent http-header
    ),
);

like literally just hand your $client a ua object and it knows what to do 🫢


✨ METHODS ✨

The following methods should be implemented β€” yes, you, subclass, this is your moment, main character behavior only πŸ’…

  • async () β€” should return true if the useragent is asynchronous, and false otherwise. That's it. That's the whole job. ⭐
  • call ( $method, $uri, body => $body, headers => { http-headers }, cb => $cb->( $response ) ); β€” should process an HTTP-request to $uri, using $method, passing $headers and $body, receive the response, and invoke $cb with an HTTP::Response object. 🌸
heads up bestie: these are the methods you're supposed to implement in your own UA class β€” this base class is just the contract, iykyk 🧚

Copyright (c) 2008-2009 Mons Anderson. πŸ’œ

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. slay, open source, we love to see it 🌈


πŸ¦‹ AUTHOR πŸ¦‹

Mons Anderson, "<mons@cpan.org>" β€” iconic, thank you for your service πŸ«‘πŸ’–


and that's the whole page, bestie!! this one came from perl v5.34.0, dated 2022-06-28, and it's filed under XML::RPC::UA(3pm). go forth and implement those two methods, periodt. πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from